Gamestudio Links
Zorro Links
Newest Posts
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
Data from CSV not parsed correctly
by EternallyCurious. 04/20/24 21:39
M1 Oversampling
by 11honza11. 04/20/24 20:57
Scripts not found
by juergen_wue. 04/20/24 18:51
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
folder management functions
by VoroneTZ. 04/17/24 06:52
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 533 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
priceClose() in TMF #478451
10/23/19 19:57
10/23/19 19:57
Joined: Aug 2019
Posts: 22
F
felixfx Offline OP
Newbie
felixfx  Offline OP
Newbie
F

Joined: Aug 2019
Posts: 22
In the TMF, priceClose() references the last tick of the bar rather than the actual Close of the bar.
Is there a way to access the last bar close and last bar open in the TMF?

also, if I was to use within a TMF if(crossOver(priceClose(), VARIABLE)) { do this action; } I get an error: Pointer Expected.
Is there a proper way of doing this?

Re: priceClose() in TMF [Re: felixfx] #478453
10/23/19 20:11
10/23/19 20:11
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Save the
Originally Posted by felixfx
In the TMF, priceClose() references the last tick of the bar rather than the actual Close of the bar.
Is there a way to access the last bar close and last bar open in the TMF?
Save each value to an AssetVar.

Originally Posted by felixfx
also, if I was to use within a TMF if(crossOver(priceClose(), VARIABLE)) { do this action; } I get an error: Pointer Expected.
Is there a proper way of doing this?
You supplied a var when you need to supply a vars.

Re: priceClose() in TMF [Re: AndrewAMD] #478464
10/24/19 17:22
10/24/19 17:22
Joined: Aug 2019
Posts: 22
F
felixfx Offline OP
Newbie
felixfx  Offline OP
Newbie
F

Joined: Aug 2019
Posts: 22
Originally Posted by AndrewAMD
Save each value to an AssetVar.


so in other words
#define CLOSE0 close[0]
#define CLOSE1 close[1]
// etc

function run()
{ vars close = series(priceClose()); }

since I have yet to figure out how to supply a whole series to a TMF, is that even possible?

Originally Posted by AndrewAMD
You supplied a var when you need to supply a vars.

This is related to the above. If I passed individual indexes within a series of priceClose() to the TMF, I would use
if(crossOver(CLOSE0, VARIABLE) { do this action; }

if this case, I would want to use the Tick priceClose() within the TMF over a bar priceClose() from run(), so what would be the proper syntax to do this within the TMF?

Re: priceClose() in TMF [Re: felixfx] #478465
10/24/19 17:42
10/24/19 17:42
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Originally Posted by felixfx
since I have yet to figure out how to supply a whole series to a TMF, is that even possible?

I explained that here:
https://opserver.de/ubb7/ubbthreads.php?ubb=showflat&Number=478454#Post478454


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