So I have been running tests on some random posted systems, as well as the ones included with Multicharts, and have a few questions on how you guys deal with slippage in your systems/backtests.
I have posted some code below, and I am wondering if someone could help make this live trading friendly. I have been backtesting this on CL and have seem some decent profitability, including commission. But I want to make sure I am backtesting this with slippage included, and doing it in a way that is relatively accurate.
I have read in a couple of different places to enter a trade at market, and exit with limits/stoplimit to avoid too much slippage. Is this the best possible scenario? I find the system below working best taking a lot of trades, with on average about 8-9 ticks of profit per trade (overall average, not every trade). So I wouldn't mind missing a couple of trades to avoid slippage. In that case would it make sense to enter with a limit/stoplimit as well?
Would love to get some help here, so I can better understand how to code systems to be more realistic for live trading. If you use limit/stoplimit orders for the below code, can you please include a good setting for the slippage setting in Mulitcharts? eg. $10 per trade or $10 per share/contract.
IF UpperStr(ZeroCrss) = "Y" Then Begin
IF TRXval Crosses Above Zero Then
Buy ("B_ZCrss") This Bar on Close;
IF TRXval Crosses Below Zero Then
Sell ("S_ZCrss") This Bar on Close;
End;
IF UpperStr(AvgCrss) = "Y" Then Begin
IF TRXval Crosses Above AvgTRX Then
Buy ("B_AvgCrss") This Bar on Close;
IF TRXval Crosses Below AvgTRX Then
Sell ("S_AvgCrssS") This Bar on Close;
End;