I need a little easylanguage help.
I'm trying to build a conditional statement based on the following. If an RSI value goes below 30, I want the conditional statement to remain true until the RSI goes back above 70. => "Once RSI<30 then true UNTIL RSI>70"
I've attached a chart demonstrating what I'm looking for. Also, here is my attempt at building this. As you can see I'm counting the number of bars since this condition was true. It compiles, however, I know that it isn't correct.
if RSIValue<30 then begin
while RSIValue<70 begin
Questions about MultiCharts and user contributed studies.
5 posts •Page 1 of 1
If I understand you correctly it should be something like this:
Code: Select all
Variables: Counter(0), MyRSICondition(false);
if RSI(close, Length) < 30 then
MyRSICondition = true;
if RSI(close, Length) > 70 then
MyRSICondition = false;