function run(){
BarPeriod = 1;
LookBack = 240*100;
StartDate = 20100101;
EndDate = 20100201;
set(NOSHIFT); //shift manually
asset("EURUSD");
vars priceM1 = series();
vars priceM5 = series();
if (is(INITRUN)){
priceM1 = series(0, 100);
priceM5 = series(0, 100);
}
TimeFrame = 1;
shift(priceM1, priceClose(), 100);
TimeFrame = 5;
if (frame(0)) shift(priceM5, priceClose(), 100);
if (!is(LOOKBACK)){
int i, j;
for (i=0; i<10; i++){
printf("\n--- M5: %.5f", priceM5[i]);
for (j=0; j<5; j++){
printf("\n M1: %.5f", priceM1[i*5+j]);
}
}
quit(0);
}
}