ok thanks for the reply so start on one minute time frame. Run the test with the number of units at 10 K units. Save the test results with a screenshot. Then leave the time frame as 1 min but change the number of units to 25000 units. Run the test again with all the same settings. You are not interested in any of the test results except the last 7 days. Compare the test from the 10K with the test of the 25k but limit yourself to only looking at the last 7 days of the test.
Then extend the number of units out to the maximum.
If the historic data is correct then the output of the last 7 days of each test should be the same. So if we look at this from the end as day 7 made 100 points on the 10 K test, it should have also made 100 pionts on the 25K test and on the longest 195,000 units as well.
If you look at the trades on the last 7 days they are all diferant in terms of the number of points won or lost in these trades.
This indicator was not written by me it was one that I found that was written by <span class=”bbp-author-name”>Nicolas</span> all I have done is changed and cleaned out the code of anything that is not necessary for the trading system.
This will work on any index, this is not an automated trade in this form as it gives out huge numbers for incorrect signals when the market goes flat or sideways. I use this for manual trades and it works very well I was just looking to fine tune the settings and found this error with the historic data. Its a type of Supertrend using STD Deviation as the source for the changes.
Try it on an index and see what you get on your trading system
my feed is PRT / IG
Grant Murray
DEFPARAM FLATAFTER = 103000
DEFPARAM FLATBEFORE = 083000
// — settings
SignalPeriod = 8
ArrowPeriod = 2.3
// — end of settings
bbup = average[signalperiod]+std[signalperiod]*arrowperiod
bbdn = average[signalperiod]-std[signalperiod]*arrowperiod
//>
if ts=0 then
if close crosses over bbup then
ts=bbdn
trend=1
elsif close crosses under bbdn then
ts=bbup
trend=-1
endif
endif
if trend=1 then
ts=max(ts,bbdn)
elsif trend=-1 then
ts=min(ts,bbup)
endif
if trend=1 and close crosses under ts then //and verify < trig then
trend=-1
ts=bbup
r=255
g=0
//drawarrowdown(barindex,ts) coloured(“red”)
//drawsegment(startbar,startts,barindex,ts) style(dottedline2) coloured(“blue”)
startbar=barindex
startts=ts
endif
if trend=-1 and close crosses over ts then //and verify > -trig then
trend=1
ts=bbdn
r=0
g=255
//drawarrowup(barindex,ts) coloured(“lime”)
//drawsegment(startbar,startts,barindex,ts) style(dottedline2) coloured(“blue”)
startbar=barindex
startts=ts
endif
//return ts coloured(r,g,0) style(dottedline,2)
// Conditions to enter long positions
IF NOT LongOnMarket AND trend = 1 and close crosses over ts THEN
BUY 1 CONTRACTS AT MARKET
ENDIF
// Conditions to exit long positions
If LongOnMarket AND trend= -1 and close crosses under ts then
SELL AT MARKET
ENDIF
// Conditions to enter short positions
IF NOT ShortOnMarket AND trend= -1 and close crosses under ts then
SELLSHORT 1 CONTRACTS AT MARKET
ENDIF
// Conditions to exit short positions
IF NOT LongOnMarket AND trend = 1 and close crosses over ts THEN
EXITSHORT AT MARKET
ENDIF
SET TARGET $PROFIT 5000