I have an atc scan and associated plot (afl below) that calculates
the % of stocks in a group which are above a moving average. The ma
periods can be changed prior to running the atc scan using Param. I
assume that the closest i can get to having an interactively-changing
plot is to run a scan for each ma period that i want to investigate.
Is this correct?
In other words, if i want to plot the % of stocks in a group which
are above a 26 period ma instead of a 50 period ma, i need to run
another atc scan, right?
tia,
Tim
////////////////////////////////////////
Filter=1;
Buy=Sell=Short=Cover=0;
MAPeriods = Param("Bars for B% MA", 50, 1, 252, 1);
Count = IIf(C > MA(C, MAPeriods), 1, 0);
sym = "~" + SectorID(1) + " Above MA";
AddToComposite(Count, sym,"C");
AddToComposite(1, sym,"I");
Bpct= (Foreign("~REAL ESTATE Above MA", "C") / Foreign("~REAL ESTATE
Above MA", "I"))*100 ;
// I'll eventually attempt to change the line above to use the
currently-displayed composite instead of a specific one
Plot(Bpct, "Bullish %", colorBlack, styleLine);