|
Post by madwill on Feb 23, 2016 23:31:57 GMT
Hi
I currently have an AFL file using Rotational mode. Does everything I want in Backtest.
I also want to use this in Explore. The reason for this is it is easy to add additional indicators using "Addcolumn"
Typically you would use Filter = Buy or Sell, for those that are not in Rotational Mode.
In Rotational mode, as per the manuals etc, it only uses "Buyprice" and not typical Buy and Sell.
Is there a way to add a Filter so you get the same results as backtest? (so I can add columns etc)
Regards Adam
Formula below for reference:
SetBacktestMode( backtestRotational );
SetOption("AllowPositionShrinking",True); SetBarsRequired(10000,10000); SetFormulaName("Strength"); SetTradeDelays( 0,0,0,0); SetOption( "initialequity", 100000 );
maxopen = Optimize("MaxOpenPositions",5,1,10,1); pctsize = ((100000/maxopen)/100000)*100;
SetOption( "MaxOpenPositions", maxopen ); SetPositionSize(pctsize,spsPercentOfEquity); SetOption("WorstRankHeld",maxopen); SetOption( "PriceBoundChecking", 1 );
Filter = 1;
SetOption( "UsePrevBarEquityForPosSizing", 1 );
MC = TimeFrameCompress( C, inMonthly); time = Optimize("RocTime",6,1,12,1);
MonthlyROC = ROC( MC,time); MonthlyROC = TimeFrameExpand( MonthlyROC, inMonthly ); PositionScore = IIf( Ref(MonthlyROC,-1) > 0, Ref(MonthlyROC,-1), 0);
AddColumn (BuyPrice,"BuyPrice",1.2); AddColumn (MonthlyROC,"Month ROC",1.2); AddColumn (PositionScore, "Position Score",1.2);
|
|
fxshrat
Private Group
Posts: 566
Received Likes: 211
|
Post by fxshrat on Feb 24, 2016 8:56:19 GMT
You can't do rotational mode in Exploration.
As for adding columns you can so in Backtest mode via Custom backtest Interface. There you can add any column too.
|
|
|
Post by madwill on Feb 24, 2016 22:19:36 GMT
Thanks fxshrat, you have assisted me before on using the Custom Backtest Interface.
regards Adam
|
|