Gamestudio Links
Zorro Links
Newest Posts
Zorro version 3.0 prerelease!
by jcl. 02/12/26 14:05
MarginCost discrepancy?
by jcl. 02/12/26 14:02
Hedge on FXCM, 4 or 5?
by qin. 02/11/26 14:12
CMC MT4 CFD vs FX Active - what's better?
by mayarik. 02/11/26 11:00
print a "still alive" log
by qin. 02/10/26 12:16
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
1 registered members (TipmyPip), 7,787 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
ApprenticeInMuc, PatrickH90, USER0328, Sfrdragon, mayarik
19198 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
AdviseLong Export Assets #476959
04/28/19 13:09
04/28/19 13:09
Joined: Apr 2019
Posts: 5
R
riinvest Offline OP
Newbie
riinvest  Offline OP
Newbie
R

Joined: Apr 2019
Posts: 5
Hi,
I am trying to export data of two assets with the AdviseLong function. Is there any way that the data is stored in two seperated csv files? Alternatively, I was thinking to define the data one of the export arrays (see exportarr[0]) by defining a counter. However, this does not seem to work either.



function run()
{

EndDate = 2017; // start two years ago
BarPeriod = 60; // use 1-hour bars
LookBack = 500; // needed for scale()
set(RULES); // generate signals

LifeTime = 10; // prediction horizon

Spread = RollLong = RollShort = Commission = Slippage = 0;

int b = 1;

while(asset(loop("EUR/USD","AUD/USD"))){


//Pre calculate indicators
//Define prices
vars Price = series(price());
vars PriceOpen = series(priceOpen());
vars PriceClose = series(priceClose());
vars PriceHigh = series(priceHigh());
vars PriceLow = series(priceLow());
vars Trend50 = series(LowPass(Price,50));
vars Trend200 = series(LowPass(Price,200));
vars Trend500 = series(LowPass(Price,500));


b=b+1;
printf("%i", b);

//Export function

//output array
var exportarr[10];
exportarr[0]= (var) b; //scale(change(1),498)/100;
exportarr[1]= scale((Trend50[0]/PriceClose[0]-1)*100,498)/100;
exportarr[2]= scale((Trend200[0]/PriceClose[0]-1)*100,498)/100;
exportarr[3]= scale((Trend500[0]/PriceClose[0]-1)*100,498)/100;
exportarr[4]= scale((rRealUpperBand/PriceClose[0]-1)*100,498)/100;
exportarr[5]= scale((rRealLowerBand/PriceClose[0]-1)*100,498)/100;
exportarr[6]= scale((MMI_Smooth[0]/MMI_Smooth[1]-1)*100,498)/100;
exportarr[7]= scale((Trend50[0]/PriceClose[0]-1)*100,498)/100;
exportarr[8]= scale((Trend200[0]/PriceClose[0]-1)*100,498)/100;
exportarr[9]= scale((Trend500[0]/PriceClose[0]-1)*100,498)/100;

adviseLong(SIGNALS+BALANCED,0, exportarr, 10);

enterLong();

b = b+1;
}
}

Re: AdviseLong Export Assets [Re: riinvest] #476966
04/29/19 08:30
04/29/19 08:30
Joined: Jul 2000
Posts: 28,072
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 28,072
Frankfurt
That's right, the csv file always has the same name regardless of the asset. We'll change that in the next update so that any asset exports to an individual signals file. Until then, train them separately.

Re: AdviseLong Export Assets [Re: jcl] #476976
04/29/19 17:14
04/29/19 17:14
Joined: Apr 2019
Posts: 5
R
riinvest Offline OP
Newbie
riinvest  Offline OP
Newbie
R

Joined: Apr 2019
Posts: 5
Thank you for your answer, looking for the next release then

Last edited by riinvest; 04/29/19 17:15.

Moderated by  Petra 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1