Wow so much stuff going on I feel. I managed to get my backtesting software in sync by manually entering trades as they occured in real life. That way I can follow along and correct discrepancies as they pop up and enter trades manually where they were different.
I did notice one difference. Two of my stock were sold yesterday and not so in the backtesting software. It turns out the trailing stop % does not really continue to be a percentage in the back testing software. It is determined to be value X as a % of the price on BUY and then remains the same through it's life time. The real life trailing stop does not work that way. I modified the code to be able to do it either way. I am now backtesting both approaches to see what I should adjust.
I also screwed up a bit with yesterday's buys. I created a bracket order with GTC sell upper limit and DAY trailing stop. I thought I would put in a new GTC trailing stop on the next day. But now I cannot find out how to link the new trailing stop to the existing SELL LMT so that if one gets triggered the other one gets cancelled. That is rather annoying. Next time I will just create a bracket order with two GTC orders and adjust the % on the trailing stop on the second day.
Also, my work is gearing up and about to get a whole lot busier probably from next week. I might not have so much time to spend on this from then on.
I did notice one difference. Two of my stock were sold yesterday and not so in the backtesting software. It turns out the trailing stop % does not really continue to be a percentage in the back testing software. It is determined to be value X as a % of the price on BUY and then remains the same through it's life time. The real life trailing stop does not work that way. I modified the code to be able to do it either way. I am now backtesting both approaches to see what I should adjust.
I also screwed up a bit with yesterday's buys. I created a bracket order with GTC sell upper limit and DAY trailing stop. I thought I would put in a new GTC trailing stop on the next day. But now I cannot find out how to link the new trailing stop to the existing SELL LMT so that if one gets triggered the other one gets cancelled. That is rather annoying. Next time I will just create a bracket order with two GTC orders and adjust the % on the trailing stop on the second day.
Also, my work is gearing up and about to get a whole lot busier probably from next week. I might not have so much time to spend on this from then on.