Hello, i am trying to code the condition where the volume would be below its average volume(10days) but only in the last 2 to 5 bars.
the start should be similar to this:
AverageVolume = MA(Volume, 10);
Filter = Volume < AverageVolume; // this would be for today's volume below the average volume
// but how to put the volume of the last 2 to 5 bars below the Average volume?
Thanks a lot for your help and quick reply. I am trying to plot to check the signal .The code seems to be working but it is only showing on the right side of the chart. Is there any way to have the condition plot when the condition is met? not only today's signal?