ELA debugging problems when tracking the intraday market as with DAX livechart - EasyLanguage Programming | futures.io
futures.io futures trading


ELA debugging problems when tracking the intraday market as with DAX livechart
Started: by gorbod Views / Replies:157 / 6
Last Reply: Attachments:2

Welcome to futures.io.

Welcome, Guest!

This forum was established to help traders (especially futures traders) by openly sharing indicators, strategies, methods, trading journals and discussing the psychology of trading.

We are fundamentally different than most other trading forums:
  • We work extremely hard to keep things positive on our forums.
  • We do not tolerate rude behavior, trolling, or vendor advertising in posts.
  • We firmly believe in openness and encourage sharing. The holy grail is within you, it is not something tangible you can download.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.


You'll need to register in order to view the content of the threads and start contributing to our community. It's free and simple, and we will never resell your private information.

-- Big Mike

Reply
 
Thread Tools Search this Thread
 

ELA debugging problems when tracking the intraday market as with DAX livechart

  #1 (permalink)
Elite Member
Sverige
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation
Favorite Futures: OMX futures
 
Posts: 4 since Aug 2014
Thanks: 1 given, 0 received

ELA debugging problems when tracking the intraday market as with DAX livechart

I have debugging problems in Easylanguage when I try to programme tracking of the Intraday high and low, both value and time. For some reason when I debugg my indicators i get yesterdays value.

Can anyone give me an advice what is wrong?

DAX live chart has that displayed
Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).

Link: Börse Frankfurt

For some reason when I debugg my indicators i get yesterdays value.
Can anyone give me an advice what is wrong?

Below is the code for the high and low value and time tracking:

variables:
DayOpen( 0 ),
DayHigh( 0 ),
DayLow( 0 ),
TimeatHigh( 0 ),
TimeatLow( 0 );

if BarType <= 1 then { ie, if minute or tick bars }
begin
if Date <> Date[1] and BarStatus( DataNum ) = 2 then { ie, if new day }
begin

{ re-initialize O,H,L for the new day }
DayOpen = Open ;
DayHigh = high ;
DayLow = low ;

{ track the new high and low }
if High > DayHigh then
begin
DayHigh = High ;
TimeatHigh = Time;
end ;

if Low < DayLow then
begin
DayLow = Low ;
TimeatLow = Time;
end ;

end ;
end
else
RaiseRunTimeError( "Requires intraday bars." ) ;

Reply With Quote
 
  #2 (permalink)
Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

 
  #3 (permalink)
 Vendor: abctradinggroup.com 
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,185 since Apr 2013
Thanks: 198 given, 678 received


gorbod,

from your code it appears you only track the high and low of the very first bar of a new day.

Something like this might get you going (I didn't test the code, though):

 
Code
variables:
DayOpen( 0 ),
DayHigh( 0 ),
DayLow( 0 ),
TimeatHigh( 0 ),
TimeatLow( 0 );

if BarType <= 1 then { ie, if minute or tick bars }
begin
if Date <> Date[1] and BarStatus( DataNum ) = 2 then { ie, if new day }
begin

{ re-initialize O,H,L for the new day }
DayOpen = Open ;
DayHigh = low; //set to low to make sure it gets updated further down
DayLow = high ; //set to high to make sure it gets updated further down
end ; //if Date <> Date[1] and BarStatus( DataNum ) = 2 then { ie, if new day }
{ track the new high and low }
if High > DayHigh then
begin
DayHigh = High ;
TimeatHigh = Time;
end ;

if Low < DayLow then
begin
DayLow = Low ;
TimeatLow = Time;
end ;

end
else
RaiseRunTimeError( "Requires intraday bars." ) ;
Regards,

ABCTG

Reply With Quote
The following user says Thank You to ABCTG for this post:
 
  #4 (permalink)
Elite Member
Sverige
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation
Favorite Futures: OMX futures
 
Posts: 4 since Aug 2014
Thanks: 1 given, 0 received

Error in values but now an another error......

Thanks now the code seems to work better and for todays high everything seems ok,
but for todays low the value is 0.
From printlog:
Date 1160902.00 IntradayHigh 2186.75 Time 1620.00 Intradaylow 0.00 Time 0.00

To ensure that there is no error in data did I save the data and made a quality ckeck in excel and the lowest value is 2164.25.

For some reason does todayshigh work fine but not todays low.
Very confusing, has Tradestation any errorhandling or memory problems causing that the variables returns a 0 or what can be the problem?

Reply With Quote
 
  #5 (permalink)
 Vendor: abctradinggroup.com 
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,185 since Apr 2013
Thanks: 198 given, 678 received

Futures Edge on FIO

Which products do you trade?

 
gorbod,

it's more likely coming either from the code or chart setup and not from a TS error or memory problem. Although the latter is a possibility I'd suggest to check out the code and setup first.
What is the exact code you used for your testing, including the print commands?

What is the exact chart setting you have been using, including interval and days back (maybe post a screenshot of the symbol settings as shown under format symbol). Is there more than one data stream on the chart? Basically provide all information that one would need to reproduce what you are seeing on your end.

Regards,

ABCTG

Reply With Quote
 
  #6 (permalink)
Elite Member
Sverige
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation
Favorite Futures: OMX futures
 
Posts: 4 since Aug 2014
Thanks: 1 given, 0 received

Thanks for your advice!
The exact code is that code you provided.

Data format 15min @ES , 10 days back, only one data stream, Screen shoot enclosed.
Can session settings cause errors in variables?
Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).

Reply With Quote
 
  #7 (permalink)
 Vendor: abctradinggroup.com 
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,185 since Apr 2013
Thanks: 198 given, 678 received

Gorbod,

thanks for the screenshot. I have added plot statements to the code and tested it. The problem is
 
Code
if Date <> Date[1] and BarStatus( Datanum ) = 2 then
won't work as Datanum returns a value of 0.

You will have to set this to the datastream you apply the study to (1 in your case) and the code will work fine.

This is a bit of a pitfall here, as the compiler shouldn't compile the code as DataNum is neither a reserved word nor a variable in your case, but TS uses DataNum as placeholder in the help file. So maybe something got mixed up.

From the TS help:
BarStatus(DataNum)

DataNum is a numeric expression representing the data stream that is being evaluated. 1 refers to Data1, 2 to Data2 and so on. DataNum can be between 1 and 50, inclusive.

Regards,

ABCTG

Reply With Quote
The following user says Thank You to ABCTG for this post:

Reply



futures.io > > > > > ELA debugging problems when tracking the intraday market as with DAX livechart

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)

2016 True Edge Awards: Voting is open until Jan 21!

Now
 

An Afternoon with FIO member Massive l

Elite only
 

Anthony Drager: Pulling the trigger with confidence

Elite only
 

Leo Murphy: The Art and Science of Technical Analysis

Elite only
 

FuturesTrader71: Ask Me Anything

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Does anyone have the ELA for Hull MA and Hurst Channels? quantum777 MultiCharts 1 June 4th, 2015 08:51 PM
Converting Tradestation ELA to R Trueblue Matlab, R project and Python 2 August 13th, 2014 05:24 PM
detecting grinding/oscillating market intraday dominikos Commodities Futures Trading 1 March 8th, 2014 11:52 AM
Intraday market profile Zsolt NinjaTrader 14 January 21st, 2013 11:23 PM
ELA Assistance on Bar Valuation and Data Series bullsandthebears Elite EasyLanguage Automated Trading 1 July 31st, 2012 07:15 PM


All times are GMT -4. The time now is 12:45 AM.

no new posts
Page generated 2017-01-18 in 0.12 seconds with 20 queries on phoenix via your IP 54.163.149.151