Gamestudio Links
Zorro Links
Newest Posts
Blobsculptor tools and objects download here
by NeoDumont. 03/28/24 03:01
Issue with Multi-Core WFO Training
by aliswee. 03/24/24 20:20
Why Zorro supports up to 72 cores?
by Edgar_Herrera. 03/23/24 21:41
Zorro Trader GPT
by TipmyPip. 03/06/24 09:27
VSCode instead of SED
by 3run. 03/01/24 19:06
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (degenerate_762), 1,114 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
sakolin, rajesh7827, juergen_wue, NITRO_FOREVER, jack0roses
19043 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Discontinued functions, macros and variables #472894
05/28/18 19:03
05/28/18 19:03
Joined: Apr 2013
Posts: 35
J
Joaquin Offline OP
Newbie
Joaquin  Offline OP
Newbie
J

Joined: Apr 2013
Posts: 35
Hi all,

Is there a list of discontinued functions, macros, and variables, and their newer versions (or at least the substitution of the previous command), as newer Zorro versions come out?

Because it is very annoying to code programs from 2 years ago and realize that in newer versions the same program does not compile.

Examples:
setf, resf, and I am pretty sure that there are many many others.

I must say that before asking here for this info, I have already look for it in the manual and in the "What's new" section. But haven't found anything yet.

Last edited by Joaquin; 05/28/18 19:14.
Re: Discontinued functions, macros and variables [Re: Joaquin] #472898
05/28/18 20:44
05/28/18 20:44
Joined: Jul 2000
Posts: 27,977
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,977
Frankfurt
Zorro is not yet old enough to have discontinued functions, at least as to my knowledge.

Re: Discontinued functions, macros and variables [Re: jcl] #472901
05/28/18 22:01
05/28/18 22:01
Joined: Apr 2013
Posts: 35
J
Joaquin Offline OP
Newbie
Joaquin  Offline OP
Newbie
J

Joined: Apr 2013
Posts: 35
ok... then what should I do to compile

// don't trade when the equity curve goes down
// and is below its own lowpass filtered value
function checkEquity()
{
// generate equity curve including phantom trades
vars EquityCurve = series(EquityLong+EquityShort);
vars EquityLP = series(LowPass(EquityCurve,10));
if(EquityLP[0] < LowPass(EquityLP,100) && falling(EquityLP))
setf(TradeMode,TR_PHANTOM); // drawdown -> phantom trades
else
resf(TradeMode,TR_PHANTOM); // profitable -> normal trades
}

? It's from the manual, I'm using Zorro 1.66. Am I missing a header file?

Re: Discontinued functions, macros and variables [Re: Joaquin] #472906
05/29/18 08:16
05/29/18 08:16
Joined: Jul 2000
Posts: 27,977
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,977
Frankfurt
The manual contains usage examples. For compiling them, just use them in a suited script.

Re: Discontinued functions, macros and variables [Re: jcl] #472908
05/29/18 08:38
05/29/18 08:38
Joined: Apr 2013
Posts: 35
J
Joaquin Offline OP
Newbie
Joaquin  Offline OP
Newbie
J

Joined: Apr 2013
Posts: 35
Thanks for your answer jcl,

the thing is that if I try to compile the function above, which I got from the online manual, in
http://www.zorro-trader.com/manual/en/trademode.htm

with Zorro 1.66, I get a compilation error saying that it does not know what is setf and resf

If I open the manual by clicking the Help button in my terminal, it is true that this same function is different:

// equity curve trading: switch to phantom mode when the equity
// curve goes down and is below its own lowpass filtered value
function checkEquity()
{
if(Train) { Lots = 1; return; } // no phantom trades in training mode
vars EquityCurve = series(ProfitClosed+ProfitOpen);
vars EquityLP = series(LowPass(EquityCurve,10));
if(EquityLP[0] < LowPass(EquityLP,100) && falling(EquityLP))
Lots = -1; // drawdown -> phantom trading
else
Lots = 1; // profitable -> normal trading
}

So, maybe I got it wrong... Is the online manual referring to a newer version than mine? I imagine that, according to your answer, that is actually what is happening here.. Am I right?

Re: Discontinued functions, macros and variables [Re: Joaquin] #472909
05/29/18 11:04
05/29/18 11:04
Joined: Jul 2000
Posts: 27,977
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,977
Frankfurt
Certainly.

Re: Discontinued functions, macros and variables [Re: jcl] #472922
05/29/18 19:29
05/29/18 19:29
Joined: Apr 2013
Posts: 35
J
Joaquin Offline OP
Newbie
Joaquin  Offline OP
Newbie
J

Joined: Apr 2013
Posts: 35
Ooops.. ok then, feel free to slap me in the face

Sorry for that :-)


Moderated by  Petra 

Gamestudio download | chip programmers | 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