Welcome to the Traders Laboratory Forums.
Coding Forum Collaborate, receive help, or discuss coding related issues.

Reply
Old 03-20-2009, 11:23 AM   #1

Join Date: Oct 2006
Location: na
Posts: 307
Ignore this user

Thanks: 33
Thanked 89 Times in 58 Posts

Finding Globex High and Low in Easylanguage

I was wondering if someone could help me out. I'm using OEC and trying to write a code that will draw a line for the globex high and globex low. I got it drawing from midnight, but just can't figure out how to get it when globex officially re-opens. EG 4:30pm EST for the ES as opposed to midnight. Any help is appreciated.
trader273 is offline  
Reply With Quote
Old 03-20-2009, 11:28 AM   #2

Tams's Avatar

Join Date: Sep 2008
Location: Geelong
Posts: 3,779
Ignore this user

Thanks: 2,084
Thanked 1,474 Times in 912 Posts

Re: Finding Globex High and Low in Easylanguage

if you post the code, I can polish it for you.
Tams is offline  
Reply With Quote
The Following User Says Thank You to Tams For This Useful Post:
trader273 (03-20-2009)
Old 03-20-2009, 11:46 AM   #3

Join Date: Oct 2006
Location: na
Posts: 307
Ignore this user

Thanks: 33
Thanked 89 Times in 58 Posts

Re: Finding Globex High and Low in Easylanguage

Here's what I currently have:

Code:
Inputs: 
Globex_Start(0000), GLOBEX_END(930);

vars:
G_H(0), G_L(0);



//BEGIN CALCULATION OF GLOBEX HIGH AND LOW //
If Time=Globex_Start then begin
G_H=High;G_L=Low;
end;

If Time> Globex_Start and Time<=Globex_End then begin
If High>G_H then G_H=High;
if Low< G_L then G_L=low;
end;
//END CALCULATION OF GLOBEX HIGH AND LOW //



Plot1(G_H,"G-High");
Plot2(G_L,"G-Low");
This one gives me the high and low from midnight, I can't seem to figure out how to tell it to go the previous day and look to see if a low or high was there.
trader273 is offline  
Reply With Quote
Old 03-20-2009, 03:05 PM   #4

Tams's Avatar

Join Date: Sep 2008
Location: Geelong
Posts: 3,779
Ignore this user

Thanks: 2,084
Thanked 1,474 Times in 912 Posts

Re: Finding Globex High and Low in Easylanguage

is your chart on 24hr session?
Tams is offline  
Reply With Quote
Old 03-20-2009, 03:12 PM   #5

Join Date: Oct 2006
Location: na
Posts: 307
Ignore this user

Thanks: 33
Thanked 89 Times in 58 Posts

Re: Finding Globex High and Low in Easylanguage

Quote:
Originally Posted by Tams »
is your chart on 24hr session?
yes it is. Can change that if necessary.
trader273 is offline  
Reply With Quote
Old 03-20-2009, 04:07 PM   #6

Tams's Avatar

Join Date: Sep 2008
Location: Geelong
Posts: 3,779
Ignore this user

Thanks: 2,084
Thanked 1,474 Times in 912 Posts

Re: Finding Globex High and Low in Easylanguage

you can declare a set of variables for the morning session, and a set of variables for the evening session.

e.g.

var:
G_morn_H(0),
G_morn_L(0),

G_even_H(0),
G_even_L(0);

then assign the respective highs and lows to the respective variables.
then plot the max of the 2 high variables, and the min of the 2 low variables.


This is the idea.
I will throw something together later tonight.
Tams is offline  
Reply With Quote
The Following User Says Thank You to Tams For This Useful Post:
trader273 (03-20-2009)
Old 03-20-2009, 04:13 PM   #7

Join Date: Oct 2006
Location: na
Posts: 307
Ignore this user

Thanks: 33
Thanked 89 Times in 58 Posts

Re: Finding Globex High and Low in Easylanguage

I'll give that a try as well. Im pretty much self taught in EL, so I appreciate any help I can get, thanks!
trader273 is offline  
Reply With Quote
Old 03-20-2009, 07:00 PM   #8

Join Date: Nov 2006
Location: N/A
Posts: 612
Ignore this user

Thanks: 62
Thanked 294 Times in 177 Posts

Re: Finding Globex High and Low in Easylanguage

Here is my version I am using. It is most likely not the best way of doing it as I am not a very efficient programmer and it is not 100% there. The minute between 23:59 and midnight is ignored, so you have a small chance of missing the high/low if it is made during that minute. I am only using it on time based charts, but I think it should work on tick and volume based charts too.

Code:
inputs:
	StartTime1	(1530),
	EndTime1	(2359),
	StartTime2	(0000),
	EndTime2	(0830),
	PlotStartTime	(0830),
	PlotEndtime	(1515),
	TLSize		(1),
	TLStyle	(1),
	ONH_Color	(red),
	ONL_Color	(green);


variables:
	ON_High(0),
	Plot_High(0),
	ON_Low(999999999),
	Plot_Low(0),
	TL_ON_High(0),
	TL_ON_Low(0),
	ONH_Txt(0),
	ONL_Txt(0),
	TextStyleHoriz(1),	 	
	TextStyleVert(1);		
	
If Time > PlotStartTime and Time[1] <= PlotStartTime then 
begin
	Plot_High = ON_High;
	Plot_Low = ON_Low;
	ON_High = 0;
	ON_Low = 999999999;
end;

if (Time >= StartTime1 and Time <= Endtime1) or (Time >= StartTime2 and Time <= EndTime2)  then
begin
	if High > ON_High then ON_High = High; 
	if Low < ON_Low then	On_Low = Low;
end ;

if Time > PlotStartTime then 
begin
	TL_ON_High = TL_New(Date, PlotStartTime, Plot_High, Date, PlotEndTime, Plot_High);
		TL_SetColor(TL_ON_High, ONH_Color);
		TL_SetSize(TL_ON_High, TLSize);	
		TL_SetStyle(TL_ON_High, TLStyle);
				
	TL_ON_Low = TL_New(Date, PlotStartTime, Plot_Low, Date, PlotEndTime, Plot_Low);
		TL_SetColor(TL_ON_Low, ONL_Color);
		TL_SetSize(TL_ON_Low, TLSize);	
		TL_SetStyle(TL_ON_Low, TLStyle);
			
	ONH_Txt = Text_New(Date, PlotEndTime, Plot_High, "ONH");
		Text_SetStyle(ONH_Txt, TextStyleHoriz, TextStyleVert);	
		Text_SetColor(ONH_Txt, ONH_Color);
					
	ONL_Txt = Text_New(Date, PlotEndTime, Plot_Low, "ONL");
		Text_SetStyle(ONL_Txt, TextStyleHoriz, TextStyleVert);	
		Text_SetColor(ONL_Txt, ONL_Color);
end;
sevensa is offline  
Reply With Quote
The Following User Says Thank You to sevensa For This Useful Post:
trader273 (03-22-2009)

Reply

Thread Tools
Display Modes Help Others By Rating This Thread
Help Others By Rating This Thread:


Similar Threads
Thread Thread Starter Forum Replies Last Post
Finding Components in a Index simple_simon Trading and the Markets 0 03-10-2009 01:13 PM
Easylanguage: Plot Points at the Extremes of High / Low nuno-online Swing Trading and Position Trading 13 02-17-2009 09:22 PM
Overnight Session: Looking at globex high & low Soultrader Technical Analysis 15 12-25-2008 08:08 PM
Finding a MENTOR / Course - Things to Look Out for rsagi Beginners Forum 33 07-11-2008 12:27 PM
Help finding IRC chatrooms that are free Adamned Market Analysis 2 10-19-2007 11:14 AM

All times are GMT -4. The time now is 12:41 PM.
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
CS to VB integration by DeskLancer
©2006-2011 Traders Laboratory, All Rights Reserved.