Gamestudio Links
Zorro Links
Newest Posts
zorro 64bit command line support
by 7th_zorro. 04/20/24 10:06
StartWeek not working as it should
by jcl. 04/20/24 08:38
Data from CSV not parsed correctly
by jcl. 04/20/24 08:32
Zorro FIX plugin - Experimental
by jcl. 04/20/24 08:30
folder management functions
by VoroneTZ. 04/17/24 06:52
lookback setting performance issue
by 7th_zorro. 04/16/24 03:08
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:46
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (7th_zorro, Aku_Aku, 1 invisible), 579 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
C-lite return array with indice #479023
02/06/20 06:27
02/06/20 06:27
Joined: Feb 2020
Posts: 2
A
AlgoDyno Offline OP
Guest
AlgoDyno  Offline OP
Guest
A

Joined: Feb 2020
Posts: 2
Hi,
this is my first post here. I just discovered Zorro and this is a gem! Thank you for your hard work!

I've opened the indicator source file to take a look at the fisher normalization function.
I have experience in C/C++ but this is the first time I look at C-lite and this syntax is a bit confusing for me:

Code
return FN[0] = Fisher(Value) + 0.5*FN[1];


Why assigning FN[0] just before the return?
like:
Code
return Fisher(Value) + 0.5*FN[1];


And then I figured out FN[1] is assigned previously in the function as the input Data[1], but not as a Fisher transform.
The return could have been:
Code
return Fisher(Value) + 0.5*Value[1];


I don't think this is the case and
Code
return FN[0] = ...
must mean something I don't know and I can't find on the net.

Thanks for your help!

Re: C-lite return array with indice [Re: AlgoDyno] #479025
02/06/20 10:49
02/06/20 10:49
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
This code

return FN[0] = Fisher(Value) + 0.5*FN[1];

sets FN[0] to the returned value.

I suppose that FN is a time series, and FN[1] is then the value that the function returned in the previous call.

https://manual.zorro-project.com/series.htm


Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1