Hi Chorlton,
I had another look through your code and have found an error. Cond1 can be RSi(2)<2 and c>ma(c,200), due to the fact that your Buy refrences the signal yesterday. Also, I'm not sure whether you remember but I included an entry filter. The entry filter is: if the open today (entry...