OmniTrader Professional Forum OmniTrader Professional Forum
forums calendars search
today this week
 
register logon control panel Forum Rules
You are currently browsing as a guest.
You should logon to access more features
A Self-Moderated Community - ALL MEMBERS, PLEASE READ!
Vote for Members who contribute the most to your trading, and help us moderate content within the Forums.


  Current location        Thread information  
OmniTrader Professional Forum
OmniLanguage Discussion
Globex volume ...
Last Activity 7/6/2025 3:47 AM
3 replies, 2973 viewings

Jump to page : 1
Now viewing page 1 [25 messages per page]
 
back reply
Printer friendly version

^ Top
ap·pren·ticeGuru

Veteran
100
Posts: 123

Joined: 10/22/2010
Location: Columbia, MD

User Profile
 
Subject : Globex volume ...
Posted : 1/13/2016 10:00 AM
Post #24956

Hello All,

I need assistance in a OL code that would decipher volume to give reading of average globex volume (6p.m. - 9:29a.m. E.S.T.) and same for RTH - 9:30a.m.-4:15p.m. for historical evaluation purposes for 1, 5, 10, etc. days. Thank You.
^ Top
Jim Dean

Sage
2000100010010010010025
Posts: 3433

Joined: 3/13/2006
Location: L'ville, GA

User Profile
 
Subject : RE: Globex volume ...
Posted : 1/13/2016 10:40 AM
Post #24957 - In reply to #24956

What symbol are you referring to?
^ Top
ap·pren·ticeGuru

Veteran
100
Posts: 123

Joined: 10/22/2010
Location: Columbia, MD

User Profile
 
Subject : RE: Globex volume ...
Posted : 1/13/2016 11:21 AM
Post #24958 - In reply to #24956

Hi Jim:

The eminis: ESH16, YMH16, and NQH16. Thanks.
^ Top
Jim Dean

Sage
2000100010010010010025
Posts: 3433

Joined: 3/13/2006
Location: L'ville, GA

User Profile
 
Subject : RE: Globex volume ...
Posted : 1/13/2016 11:58 AM
Post #24959 - In reply to #24956

I'm not exactly sure what you mean by the list of days, but it's likely to require much more complex coding to be able to input #days ... presumably for an intraday current timeframe. So, the code below leaves that up to you ... you decide how many bars must be in the average to cover the calendar time span that you want. This code extracts the bars for APPROX the time windows you specified for the unweighted sum of those three symbols ... the precise windows can be coded but too time consuming for me right now, especially at N/C ;~)

#Indicator
#param "AvgPds", 20, 10, 40
#param "DayNiteBoth", 1, 1, 3
dim Globex, AvGX, Live as single
if bardayofmonth()<>bardayofmonth()[1] then Globex = 0
if DayNiteBoth = 1 or DayNiteBoth = 3 and barhour()>=9 and barhour()<=16 then Live=true
if DayNiteBoth = 2 or DayNiteBoth = 3 and barhour()>=18 or barhour()<=9 then Live=true
if Live then Globex = GetVolume("ESH16")+GetVolume("YMH16")+GetVolume("NQH16")
if bar >= AvgPds then
AvGX = SMA(Globex,AvgPds)
plot("AvGX",AvGX)
end if
return AvGX

... have not tested the code but barring some dumb syntax typo it should work fine.
Jump to page : 1
Now viewing page 1 [25 messages per page]
back reply

Legend    Action      Notification  
Administrator
Forum Moderator
Registered User
Unregistered User
E-Mail this thread to a friend
Toggle e-mail notification


Nirvana Systems
For any problems or issues please contact our Webmaster at webmaster@nirvsys.com.