Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (AndrewAMD, Aku_Aku, ozgur), 1,095 guests, and 0 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
ATR, DomPhase and TimeFrame crash #441501
05/25/14 12:30
05/25/14 12:30
Joined: Oct 2013
Posts: 18
5
512mb Offline OP
Newbie
512mb  Offline OP
Newbie
5

Joined: Oct 2013
Posts: 18
Got inconsistant series here:

function run()
{
BarPeriod = 15;
// TimeFrame=2;// uncomment to crash

vars Price = series(price());
vars DomPhase=series(sin(DominantPhase(Price,80)+PI/4));

if(rDominantPeriod>40)
if((ATR(5)/PIP)>1)
{}

// Workaround:
// var x=ATR(5)/PIP;
// if(rDominantPeriod>40)
// if(x>1)
// {}
}

Also there is 'i' omitted in word "Automation" in Zorro window and in the manual. cool

Re: ATR, DomPhase and TimeFrame crash [Re: 512mb] #441517
05/26/14 02:19
05/26/14 02:19
Joined: Jul 2013
Posts: 522
D
dusktrader Offline
User
dusktrader  Offline
User
D

Joined: Jul 2013
Posts: 522
Hey 512mb, check the manual on ATR function. It does say that when TimeFrame>1, that ATR() will internally create a series (therefore, the ATR-created series becomes inconsistent since it wouldnt be called on every iteration).

You can't create a series inside of conditional statement. Instead, I think your workaround is the correct solution in this case.

Re: ATR, DomPhase and TimeFrame crash [Re: dusktrader] #441522
05/26/14 08:14
05/26/14 08:14
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt
As to the missing "i", there is no word "Automation" in the Zorro manual - that might be the reason that you can't find the "i" wink.

Re: ATR, DomPhase and TimeFrame crash [Re: jcl] #441534
05/26/14 11:45
05/26/14 11:45
Joined: Oct 2013
Posts: 18
5
512mb Offline OP
Newbie
512mb  Offline OP
Newbie
5

Joined: Oct 2013
Posts: 18
Thanks,

Yes there is word "Automaton" in online manual-in Site Map.

Last edited by 512mb; 05/26/14 11:51.
Re: ATR, DomPhase and TimeFrame crash [Re: 512mb] #441535
05/26/14 11:57
05/26/14 11:57
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt

Re: ATR, DomPhase and TimeFrame crash [Re: jcl] #441555
05/26/14 23:57
05/26/14 23:57
Joined: Sep 2013
Posts: 504
California
G
GPEngine Offline
User
GPEngine  Offline
User
G

Joined: Sep 2013
Posts: 504
California


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