Dublin Ireland
Experience: Intermediate
Platform: Ninja, TOS
Broker: RCG Direct/Continuum
Trading: ZB
Posts: 18 since Mar 2012
Thanks Given: 4
Thanks Received: 7
|
"I have 'Span A' defined as:
def "Span A" = (Tenkan[kijun_period] + Kijun[kijun_period]) / 2;
Now I want to plot the last value for "Span A" as a line across the entire chart."
We need to GetValue("Span A", GetMaxValueOffset("Span A", 1), 0);
and then plot it as a priceLine
At least in theory - I gave it a go but couldn't get it to work below is the code for a horizontal priceline plotting the close of the current bar - I tried adapting it but couldn't get it to work and couldn't spend anymore time on it but left the post here to see if it was any help to you.
plot priceLine = highestAll(if isNan(close[-1]) and !isNAN(close) then close else double.nan);
Good Luck.
|