Need help with an AFL syntax

pratapvb

Well-Known Member
#11
Pratap,



Lets say i want to use the value of ktop in a formula, such as x = 10 times ktop. How do i define it ? If i type x = 10*ktop , its not working.
It will work. What do you want to with x? Just plot x and see. Also remember that ktop is an array with one value each for each bar in chart
 

akhill

Well-Known Member
#12
Prathap,

Please check this screenshot



how do I call the function for keltner bands top or bottom please ? thanks for ur patience :)


Moreover, KBTop and KBBot are also not turning blue, indicating not a valid functions.
 

pratapvb

Well-Known Member
#13
Prathap,

Please check this screenshot



how do I call the function for keltner bands top or bottom please ? thanks for ur patience :)


Moreover, KBTop and KBBot are also not turning blue, indicating not a valid functions.
KTop = CenterLine + Width * ATR( Periods );
KBot = CenterLine - Width * ATR( Periods );

Ktop and KBot are variable not function, so you can use that directly where you want to use x.

even x = Ktop ; will work and create a variable = to Ktop variable but that is unnecessary as you can use Ktop itself as that variable
 
Last edited:

Similar threads