Quote from bwolinsky:
Incidentally, if you ever want to use Tradestation or Multicharts, I recommend Multicharts.
Here is your code:
inputs:
tgt(7.5),
stp(11);
variables:
bull(1),
shit(1);
if marketposition>0 then begin
bull=entryprice+tgt;
shit=entryprice-stp;
end;
if marketposition=0 and time>0929 and time<0931 and o[1]>c[1] then begin buy next bar at market;end;
if marketposition>0 then begin
sell next bar at bull limit;
sell next bar at shit stop;
end;
if marketposition>0 and time>1599 then begin sell next bar at market;end;
Below is the equity curve with a realistic 2 tick slippage and $3 per side commission.
From -$24,690, to +$2800. I increased your profit margin infinitely with 30 minutes of optimization.
Your most optimal parameters were a 7.25 point target in ES, 11 point stop, and a $375 threshold with 95% give back trailing stop. I guess the trailing stop is nonfunctional and did not improve results. Could be a breakeven trail stop what with the 95% give back.