I'm trying to create an indicator (starting from the Strategy Builder), that will give me a signal when the following exists:
* Current 15 minute price bar is above previous 15 minute price bar ... and/or
* Current 30 minute price bar is above previous 30 minute price bar... and/or
* Current 60 minute price bar is above previous 60 minute price bar... and/or
* Current Daily price bar is above previous Daily price bar... and/or
* Current Weekly price bar is above previous Weekly price bar... and/or
* Current Monthly price bar is above previous Monthly price bar... THEN
Draw a blue upward angling arrow on chart... OR
If two or more of the above exist, draw two blue arrows
The inverse setups would draw a brown downward arrow (or two) on the chart
My question is, is this code in any way correct? A starting point? Completely wrong?
I know that I don't have the code added to draw the second arrow yet; I'll try to figure that out later.
Later on, I also plan to have a "current price bar broke out beyond previous price bar" code set that will draw different colored arrows.
Screenshot of NinjaScript code attached.
Comment