So,

for the better illustration I use the WORKSHOP_7

Code:
// Machine learning ////////////////////////////
#include <profile.c>

function run()
{
	StartDate = 2010;
	EndDate = 2018;
	BarPeriod = 1440; // 1 day
	BarZone = WET; // Western European midnight
	Weekend = 1;	// don't merge Friday and Sunday bars
//	NumWFOCycles = 5;
	asset("EUR/USD");
	
	//set(RULES+TESTNOW);
	NumTrainCycles = 2;
	if(TrainCycle == 1) set(RULES);
	else if(TrainCycle == 2) set(PARAMETERS);
  	else if(TrainCycle == 0) set(RULES|PARAMETERS|FACTORS); 

	if(Train) Hedge = 2;	// for training, allow long + short	
	LifeTime = 3;  		// one week
	MaxLong = MaxShort = -1;

>>>	int nTr=optimize(50,10,100); <<< NO work?

	if(adviseLong(PATTERN+FAST+2+RETURNS,0,
		priceHigh(2),priceLow(2),priceClose(2),
		priceHigh(1),priceLow(1),priceClose(1),
		priceHigh(1),priceLow(1),priceClose(1),
		priceHigh(0),priceLow(0),priceClose(0)) > nTr)
		enterLong();
	
	if(adviseShort() > nTr)
		enterShort();

	PlotWidth = 600;
	PlotHeight1 = 300;
	//plotTradeProfile(40);
	//plotWFOCycle(Equity,0);
	//plotWFOProfit();
}



Train output:


Workshop7 compiling...............
Rules: Workshop7 2010..2018
Train EURUSD_L 37 patterns
Train EURUSD_S 52 patterns
Rules stored in Workshop7.c

Question is, why not had start the training cycle two


Last edited by Grat; 06/09/19 06:15.