(MA Visual 1.0) VivapeiroGlimpse1.1 free

by Fron in category Trend at 24/01/2021
Description

NOW CHOOSE FROM 8 DIFFERENT TYPES OF MOVING AVERAGES 

-IMPROVE!! THE VISUAL VIEW  OF MA'S

-COLOR WILL CHANGE WHEN ABOVE OR BELOW MA

-PARAMETERS WOULD TAKE (OHLC),PERIODS,MA TYPE

-IF YOU ONLY USE Exponential Moving Average HERE is the link (CLICK HERE)

GET YOUR MERCH AT VIVAPEIRO.COM

vivapeiro.com

 

Notification Publishing copyrighted material is strictly prohibited. If you believe there is copyrighted material in this section you may use the Copyright Infringement Notification form to submit a claim.
Formula / Source Code
Language: C#
Trading Platform: cAlgocTrader
´╗┐using System;
using cAlgo.API;
using cAlgo.API.Internals;
using cAlgo.API.Indicators;
using cAlgo.Indicators;

namespace cAlgo
{
    [Indicator(IsOverlay = true, TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
    public class NewIndicator : Indicator
    {
        [Parameter("Periods", DefaultValue = 9)]
        public int perid { get; set; }

        [Parameter("Source Price")]
        public DataSeries Source { get; set; }

        [Parameter("MA Type", DefaultValue = MovingAverageType.Exponential)]
        public MovingAverageType MA { get; set; }


        protected override void Initialize()
        {

        }

        public override void Calculate(int index)
        {
            var vma = Indicators.MovingAverage(Source, perid, MA);

            for (var i = 0; i < Bars.Count; i++)
            {
                var Price = Source[i];
                var Value = vma.Result[i];
                var barColor = Price > Value ? Color.FromHex("#00868A") : Color.FromHex("#D19292");
                Chart.SetBarColor(i, barColor);
            }
        }
    }
}
Comments
5