The Economic Events Collection for MultiCharts - futures io
futures io futures trading



The Economic Events Collection for MultiCharts


Discussion in MultiCharts

Updated
      Top Posters
    1. looks_one Nicolas11 with 10 posts (21 thanks)
    2. looks_two Jura with 9 posts (46 thanks)
    3. looks_3 Wouter with 5 posts (2 thanks)
    4. looks_4 knias with 3 posts (0 thanks)
      Best Posters
    1. looks_one Jura with 5.1 thanks per post
    2. looks_two Nicolas11 with 2.1 thanks per post
    3. looks_3 SARdynamite with 2.0 thanks per post
    4. looks_4 Locust with 1.7 thanks per post
    1. trending_up 17,020 views
    2. thumb_up 83 thanks given
    3. group 23 followers
    1. forum 51 posts
    2. attach_file 18 attachments




Welcome to futures io: the largest futures trading community on the planet, with well over 125,000 members
  • Genuine reviews from real traders, not fake reviews from stealth vendors
  • Quality education from leading professional traders
  • We are a friendly, helpful, and positive community
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts
  • We are here to help, just let us know what you need
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.

-- Big Mike, Site Administrator

(If you already have an account, login at the top of the page)

 
Search this Thread
 

The Economic Events Collection for MultiCharts

(login for full post details)
  #1 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received

Have you ever wanted to work with upcoming economic events in MultiCharts, such as getting an alert when a certain economic release was about to happen? Perhaps you even wished for an way to close strategy positions a given number of minutes before an economic new release?

Introducing the Economic Events Collection for MultiCharts
Those wishing days are over with the Economic Events Collection for MultiCharts, which is a collection of functions to work with future and historical economic events.

The Economic Events Collection was designed for flexibility and usability – giving it endless possibilities while keeping the amount of code required to an absolute minimum.

For whom might the Economic Events Collection for MultiCharts be useful?
  • If you’re an automated trader and want to close open positions 10 minutes before a high impact economic event is released;
  • If you’re a discretionary trader and don’t want to be caught off guard with important economic releases or speeches and summits about market moving topics;
  • If you’re an option trader and want to open volatility-based option strategies (like straddles and strangles) in the 30 minutes before important, market moving news;
  • If you’re a backtester and want to backtest the market reactions on certain historical economic events, or just don’t want to hold a position when a historical economic event happened (like a Non-Farm Payroll release).

Using the Economic Events Collection
To start using the Economic Events Collection for MultiCharts, download the zip file from the downloads section (which contains all the files you’ll need) and follow the easily-to-follow steps in the thorough 23-page manual (attached to this post).

  • An example indicator that uses the Economic Events Collection for MultiCharts can be found here.

Support and getting help
If you run into difficulties or getting stuck repeatedly, add your question/problem to this thread and I’ll try my best to help you.

Also, if you have any suggestion for improvements, I’d be grateful if you shared them here so that the Economic Events Collection can be further expanded and improved.

Thanks
I want to give a big thanks to @Nicolas11 for helping me make this project a reality and creating an impressive Java program. Thanks Nicolas, without your help this project would never even have started.

Attached Thumbnails
The Economic Events Collection for MultiCharts-eecollectionformulticharts_v1.14_manual.pdf  
Started this thread Reply With Quote

Can you help answer these questions
from other members on futures io?
Locate candles 15 cent
ThinkOrSwim
Multicharts Custom instrument
MultiCharts
Error with loading custom futures
TradeStation
Financial Modeling Prep (free to use: financialmodelingprepcom) API
Trading Reviews and Vendors
Platform that supports grouped, linked, compound, or trigger-based orders?
Platforms and Indicators
 
Best Threads (Most Thanked)
in the last 7 days on futures io
The war of the two worlds (options traders vs futures traders)
109 thanks
Big Mike in Ecuador
54 thanks
Spoo-nalysis ES e-mini futures S&P 500
50 thanks
The Small Exchange (www.smallexchange.com)
47 thanks
How did you learn to trade?
37 thanks
 
(login for full post details)
  #2 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received

Upcoming Economic Events indicator

This indicator plots a text box on the chart with the upcoming economic events:


In this screenshot, taken on 15:56 local time (Western-Europe), you can see that Geithner was about to speak in 4 minutes (a Medium impact event) and the business inventories were also announced in four minutes.

The indicator has the following settings:


Most of these settings are self-explanatory. The 'TicksOffSetBottom' is the number of ticks you want the text box be displayed above the lowest value on the price scale. The 'RecalcAfter' is the number of seconds the box is updated - this is included to prevent excessive updating from MultiCharts to keep everything running smoothing.

Important note: You'll need the Economic Events Collection for MultiCharts (see first post in this thread and download here) to work with this indicator.

This indicator can be downloaded here.

Started this thread Reply With Quote
The following 12 users say Thank You to Jura for this post:
 
(login for full post details)
  #3 (permalink)
Germany
 
Experience: Advanced
Platform: Quanthouse, Multicharts
Broker: IB / IQ / EBS-ETS
Trading: FDAX, FGBL, FGBM, CL, ES
 
Locust's Avatar
 
Posts: 96 since Aug 2010
Thanks: 40 given, 113 received


Hello,

first of all, thanks to everybody involved in this great tool !!!
This saves a lot of manual work.

I have one problem, after installing it in the 64 bit beta of MC.
The Indicator just pops up for a few seconds in my chart and then disappears again.
Every time when i add it to a chart or turn it on or off it repeats the same pattern, appearing for a few seconds
and then disappearing again.

Regards

Locust

Visit my futures io Trade Journal Reply With Quote
The following user says Thank You to Locust for this post:
 
(login for full post details)
  #4 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received


Locust View Post
I have one problem, after installing it in the 64 bit beta of MC.
The Indicator just pops up for a few seconds in my chart and then disappears again.
Every time when i add it to a chart or turn it on or off it repeats the same pattern, appearing for a few seconds
and then disappearing again.

Hi Locust,

That sounds like an annoying problem. How does it disappear - does it so silently or gives it an error message and then turns itself off? If so, what's the error message? You probably have, but to check: have you installed the 64 bit version of the ELCollection.DLL? Do other indicators in the MC8 beta work correctly or does this behaviour occurs more often?


Started this thread Reply With Quote
 
(login for full post details)
  #5 (permalink)
Germany
 
Experience: Advanced
Platform: Quanthouse, Multicharts
Broker: IB / IQ / EBS-ETS
Trading: FDAX, FGBL, FGBM, CL, ES
 
Locust's Avatar
 
Posts: 96 since Aug 2010
Thanks: 40 given, 113 received

Completely silent, no error message at all everything else so far works perfect with the new beta. It looks like just redraw of the background when the data disappears, maybe triggered by an update in the chart like a tick etc.
(And yes I have installed the 64 bit version.) When i switch the status on and off it always reappears for a short but different amount of time.




Jura View Post
Hi Locust,

That sounds like an annoying problem. How does it disappear - does it so silently or gives it an error message and then turns itself off? If so, what's the error message? You probably have, but to check: have you installed the 64 bit version of the ELCollection.DLL? Do other indicators in the MC8 beta work correctly or does this behaviour occurs more often?



Locust

Visit my futures io Trade Journal Reply With Quote
 
(login for full post details)
  #6 (permalink)
Germany
 
Experience: Advanced
Platform: Quanthouse, Multicharts
Broker: IB / IQ / EBS-ETS
Trading: FDAX, FGBL, FGBM, CL, ES
 
Locust's Avatar
 
Posts: 96 since Aug 2010
Thanks: 40 given, 113 received

I think i just found the answer myself. I had checked update on every tick. Once this was turned off the data stayed on the chart even though data was updated around it.





Locust View Post
Completely silent, no error message at all everything else so far works perfect with the new beta. It looks like just redraw of the background when the data disappears, maybe triggered by an update in the chart like a tick etc.
(And yes I have installed the 64 bit version.) When i switch the status on and off it always reappears for a short but different amount of time.


Locust

Visit my futures io Trade Journal Reply With Quote
The following 4 users say Thank You to Locust for this post:
 
(login for full post details)
  #7 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received


Locust View Post
I think i just found the answer myself. I had checked update on every tick. Once this was turned off the data stayed on the chart even though data was updated around it.

Thanks for the update Locust, and glad you got it working.

Started this thread Reply With Quote
 
(login for full post details)
  #8 (permalink)
Newcastle, Australia
 
Experience: Intermediate
Platform: Multicharts 8 - Full Version
Broker: IB
Trading: SPI,FTSE100, 6E, 6A
 
Posts: 285 since Oct 2010
Thanks: 108 given, 185 received

Hi,
Having a bit of an issue where not all of the events are being displayed.
I think this relates to my locale. I'm at GMT+10, so I have set the "myTimeZoneOffSet = 16;" allowing for DST.
In the download events file, I have the following -
1120308,1930,3,AUD,Trade Balance
1120308,2030,3,CNY,CPI y/y
1120308,2030,2,CNY,PPI y/y
1120309,0200,1,EUR,German Final CPI m/m
1120309,0200,1,EUR,German Trade Balance

The German events are being correctly displayed as happening this evening (9th March) @ 1800 hrs my time. This is as per ForexFactory.
However, the preceding events (AUD & CNY) are not being displayed at all.
Note the date stamp on these, prior day. But they are for today at (09 March 2012) @ 11:30AM and 12:30AM.
So I'm guesing that the TimeZoneOffSet is doing the time offset but not the date adjustment.

Am I missing a setting somewhere?

Neil.

Reply With Quote
The following user says Thank You to NW27 for this post:
 
(login for full post details)
  #9 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received


NW27 View Post
So I'm guesing that the TimeZoneOffSet is doing the time offset but not the date adjustment.

You're completely correct Neil - thanks for raising the issue here. I was able to replicate it here, so it's not related to your settings etc.

I've attached an updated EE.ReadFile function which adjusts the date (and not just the hours). The settings and other functions can be left untouched, only the ReadFile function needs to be replaced.

With the updated function, I get the following output when using TimeZoneOffSet of 16:



Where the notepad is in EST, and the events on the left on TimeZoneOffSet 16.

(Note that the remaining minutes calculation is wrong here, since my pc's local time is not on Australia time, so the first events have already passed but are still displayed here for that reason.)

Let me know if you run into other problems or the TimeZoneOffSet still gives you problems.

-----

Note: importing the attached EE.ReadFile function will overwrite the existing. For users that have modified the EE.ReadFile function, the following lines...

 
Code
    dateNum        = StrToNum(LeftStr(rawStr, 7));
    
    // Check to see if the date falls in the range specified, if Yes, then continue
    if (dateNum >= FromDate) and (dateNum <= ToDate) then begin
        timeNum        = DateTime2ELTime(ELTimeToDateTime(StrToNum(MidStr(rawStr, 9, 4))) + timeZoneOffset);
..were replaced with:

 
Code
    dtEvent        = ELDateToDateTime(StrToNum(LeftStr(rawStr, 7))) + ELTimeToDateTime(StrToNum(MidStr(rawStr, 9, 4))) + timeZoneOffset;
    dateNum        = JulianToDate(dtEvent);
    
    // Check to see if the date falls in the range specified, if Yes, then continue
    if (dateNum >= FromDate) and (dateNum <= ToDate) then begin
        
        timeNum        = DateTime2ELTime(ELTimeToDateTime(StrToNum(MidStr(rawStr, 9, 4))) + timeZoneOffset);

Attached Files
Register to download File Type: pla EE.ReadFile_v1.1.pla (7.3 KB, 47 views)
Started this thread Reply With Quote
The following 4 users say Thank You to Jura for this post:
 
(login for full post details)
  #10 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received


Hi,

Forex Factory has recently modified the HTML code behind its calendar of economic events .

So v1 of EconomicEventsDownloader.jar is not able any more to retrieve the information from Forex Factory Web site.

Enclosed please find a new version (v2) of EconomicEventsDownloader.jar which solves this issue.

As for v1, the enclosed ZIP also contains source code. This source code is useless for the execution of EconomicEventsDownloader.jar. It is just given as a reference if, for any reason (for instance: security), you prefer to review the code and compile yourself the .jar file.

Thanks to @Jura for having spotted the problem in v1, and also having identified a problem (now solved) in beta version of v2. Remaining bugs, if any, are mine.

Nicolas

PS - Forex Factory also limited the historical information available. We cannot obtain economic events prior to 2009 (versus 2007 previously).

Attached Files
Register to download File Type: zip EconomicEventsDownloader_v2.zip (26.2 KB, 77 views)
Visit my futures io Trade Journal Reply With Quote
The following 7 users say Thank You to Nicolas11 for this post:
 
(login for full post details)
  #11 (permalink)
Groningen, Nederland
 
Experience: Intermediate
Platform: Multicharts lifelong license
Broker: Trying out different datafeeds..
Trading: option combinations on indices, futures on indices
 
Posts: 21 since Jun 2012
Thanks: 7 given, 2 received

Hello Jura, hello everyone in the group,

just read the posts, and start doing my dowloading and installing.

Downloaded and installed all the 54 Powerlanguage functions...

I think correctly filled in the code names in the EEUSERsettings Powerlanguage function ( at leats it compiled ok )

Got the Economic upcoming Events indicator into the PL library ok..

Downloading of Historical and future events from forexfactory went ok ( after reading this post I changed V1 into V2 for downloading of forexfactory data)


and now my problem....
I did not download the El.Collections.DLL...I followed the link to the Tradestation forum, but cannot get in that forum.
I tried to run the indicator into Multicharts, and it gave me the warning also that I neaded to download the EL.Collections DLL...
Could anyone help me on where to download the EL.Collections.DLL?

Thanks everyone

Greetings from the Netherlands

Reply With Quote
 
(login for full post details)
  #12 (permalink)
Portland, OR
 
Experience: Intermediate
Platform: Sierra Chart
Trading: ES
 
Posts: 269 since Jan 2011
Thanks: 327 given, 180 received

Attached is the elcollections.zip file - this is for 32 bit version.

Attached Files
Register to download File Type: zip 20060301130930ELCollections.zip (264.1 KB, 51 views)
Reply With Quote
The following 2 users say Thank You to ejtrader for this post:
 
(login for full post details)
  #13 (permalink)
Groningen, Nederland
 
Experience: Intermediate
Platform: Multicharts lifelong license
Broker: Trying out different datafeeds..
Trading: option combinations on indices, futures on indices
 
Posts: 21 since Jun 2012
Thanks: 7 given, 2 received

Thanks Gonna try it right now

Reply With Quote
 
(login for full post details)
  #14 (permalink)
Groningen, Nederland
 
Experience: Intermediate
Platform: Multicharts lifelong license
Broker: Trying out different datafeeds..
Trading: option combinations on indices, futures on indices
 
Posts: 21 since Jun 2012
Thanks: 7 given, 2 received

Hi Jura, - and Nicolas,

just downloaded the attached file.
And found 4 files in ti, and subtracted the "EL Collections DLL", and put that into my C/ProgramFiles/Multicharts/"El Collections DLL"

Now I tried starting up MC again with the Economic Events Upcoming Events indicator..
And again I found the same warning, stating that ..""Cant find ELCollections DLL"...I did restart my pc.

Now I am thinking, in the imputs section of Econmic events Upcoming Events indicator, I have the option to fill in the name of the list, it says "Mylist2" .

That probably has to corresponds with the names I put in the Function"EEUserssettings" and ,that on its turn with the names of the 2 V2 files ( forexfactory data), being 1. historicaleconomicevents and 2 futureeconomicevents..

I did choose in the imputs sections of the Econmic upcoming events indicator one of the 2 forexfactory files,
so either historicalevents or futureevents....is that correct that I have to choose for either historical or future data for the indicator?

I think is just a little thing I am missing

Thanks

Reply With Quote
 
(login for full post details)
  #15 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received


Wouter View Post
And found 4 files in ti, and subtracted the "EL Collections DLL", and put that into my C/ProgramFiles/Multicharts/"El Collections DLL"

Now I tried starting up MC again with the Economic Events Upcoming Events indicator..
And again I found the same warning, stating that ..""Cant find ELCollections DLL"...I did restart my pc.

You should place the .DLL file in the MultiCharts directory, not the folder itself since then MultiCharts can't find it.

Like this:



Let us know how that goes.

Started this thread Reply With Quote
The following 4 users say Thank You to Jura for this post:
 
(login for full post details)
  #16 (permalink)
Groningen, Nederland
 
Experience: Intermediate
Platform: Multicharts lifelong license
Broker: Trying out different datafeeds..
Trading: option combinations on indices, futures on indices
 
Posts: 21 since Jun 2012
Thanks: 7 given, 2 received

Hi Jura, Nicolas, EjTrader,

refreshed my MC - directory - , and as a result was finally able to place the EL.Collections.DLL into the right directory.
So no more warnings on that part

Now I see Error locations, and unable to open requested file, so I will look to match the naming of the lists.
Slowly getting there Thanks

Reply With Quote
The following user says Thank You to Wouter for this post:
 
(login for full post details)
  #17 (permalink)
Groningen, Nederland
 
Experience: Intermediate
Platform: Multicharts lifelong license
Broker: Trying out different datafeeds..
Trading: option combinations on indices, futures on indices
 
Posts: 21 since Jun 2012
Thanks: 7 given, 2 received

Have some movements No more warnings, I now have the Upcoming events indicator on, and seen the first plotting on my chart..."Date Time Minutes Impact Events"

Gonna look into making lists, but wanted to share my joy of the progress


Reply With Quote
The following user says Thank You to Wouter for this post:
 
(login for full post details)
  #18 (permalink)
Switzerland
 
Experience: Advanced
Platform: Multicharts, nothing else
Broker: Interactive Brokers
Trading: Futures: DAX, ESTX50, BUND, SMI Forex: CHF, EUR, USD
 
RoboTrade's Avatar
 
Posts: 13 since Apr 2010
Thanks: 10 given, 2 received

Hi Guys

First of all, thank you very much for this great work.
Anybody know why V2 do not collect the data? Please see the attachment.

Advice is very appreciated
Thanks a lot

Attached Thumbnails
Click image for larger version

Name:	Capture.JPG
Views:	79
Size:	75.9 KB
ID:	88425  
Reply With Quote
 
(login for full post details)
  #19 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

Hi @RoboTrade,

Were you using it before and now it doesn't work any more or is it the first time you use it?

Have you installed it in a directory on which normal user (versus: administrator, root) has all read/write rights?

Nicolas

Visit my futures io Trade Journal Reply With Quote
The following user says Thank You to Nicolas11 for this post:
 
(login for full post details)
  #20 (permalink)
Switzerland
 
Experience: Advanced
Platform: Multicharts, nothing else
Broker: Interactive Brokers
Trading: Futures: DAX, ESTX50, BUND, SMI Forex: CHF, EUR, USD
 
RoboTrade's Avatar
 
Posts: 13 since Apr 2010
Thanks: 10 given, 2 received

Dear Nicolas11

Thank you very much for your fast reply, after your thoughts, I copied the file form the folder "Program Files" to the desktop and.... the download form ForexFactory is working
What should i do for let it work in a folder of the "Program Files"?
THX again

Attached Thumbnails
Click image for larger version

Name:	Capture2.JPG
Views:	49
Size:	92.5 KB
ID:	88432  
Reply With Quote
 
(login for full post details)
  #21 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

@RoboTrade,

It is a Windows issue, and I am not expert in it. I hope somebody else will step in to give better advise.

Two ideas which come to my mind are:
1) Keep it outside "Program Files"
or
2) Run the .jar as an administrator (option usually available on right-click)

Nicolas

Visit my futures io Trade Journal Reply With Quote
The following user says Thank You to Nicolas11 for this post:
 
(login for full post details)
  #22 (permalink)
Switzerland
 
Experience: Advanced
Platform: Multicharts, nothing else
Broker: Interactive Brokers
Trading: Futures: DAX, ESTX50, BUND, SMI Forex: CHF, EUR, USD
 
RoboTrade's Avatar
 
Posts: 13 since Apr 2010
Thanks: 10 given, 2 received


Nicolas11 View Post
@RoboTrade,

It is a Windows issue, and I am not expert in it. I hope somebody else will step in to give better advise.

Two ideas which come to my mind are:
1) Keep it outside "Program Files"
or
2) Run the .jar as an administrator (option usually available on right-click)

Nicolas

THX a lot Nic

1) easy doing, because
2) not available in my Win7

Reply With Quote
 
(login for full post details)
  #23 (permalink)
Nambour, QLD, AU
 
 
Posts: 3 since Sep 2011
Thanks: 0 given, 0 received

Hi Nicolas,

I got error message as follows,

 
Code
[1/2] Download, parse and store Forex Factory economic events for the current month (10/2012)...

Problem in parsing string corresponding to 10/2012
main.ParseStringAndSave.parseStringAndSaveToFile(ParseStringAndSave.java:219)
main.Main.step3_proceedForFutureEconomicEvents(Main.java:133)
main.Main.main(Main.java:314)

Problem for identification of country in: 93.6%
main.ParseStringAndSave.parseStringAndSaveToFile(ParseStringAndSave.java:170)
main.Main.step3_proceedForFutureEconomicEvents(Main.java:133)
main.Main.main(Main.java:314)
Please help me. Thanks.

Reply With Quote
 
(login for full post details)
  #24 (permalink)
London
 
 
Posts: 118 since Mar 2010
Thanks: 42 given, 58 received


imoneyfish View Post
Hi Nicolas,

I got error message as follows,

 
Code
[1/2] Download, parse and store Forex Factory economic events for the current month (10/2012)...

Problem in parsing string corresponding to 10/2012
main.ParseStringAndSave.parseStringAndSaveToFile(ParseStringAndSave.java:219)
main.Main.step3_proceedForFutureEconomicEvents(Main.java:133)
main.Main.main(Main.java:314)

Problem for identification of country in: 93.6%
main.ParseStringAndSave.parseStringAndSaveToFile(ParseStringAndSave.java:170)
main.Main.step3_proceedForFutureEconomicEvents(Main.java:133)
main.Main.main(Main.java:314)
Please help me. Thanks.

Read the thread at MultiCharts again. Read it again carefully and make sure you follow the instructions step by step. Do not skip instructions. You can make it work.

Reply With Quote
 
(login for full post details)
  #25 (permalink)
Nambour, QLD, AU
 
 
Posts: 3 since Sep 2011
Thanks: 0 given, 0 received


Bimi View Post
Read the thread at MultiCharts again. Read it again carefully and make sure you follow the instructions step by step. Do not skip instructions. You can make it work.


i followed all the instructions, and this is the downloader, not the indicator itself have problems? Could you give me more hints? Thanks.

Reply With Quote
 
(login for full post details)
  #26 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

Hi @imoneyfish,

Are you sure that you use v2?
(Answer is on the title of the window.)

Nicolas

Visit my futures io Trade Journal Reply With Quote
 
(login for full post details)
  #27 (permalink)
Nambour, QLD, AU
 
 
Posts: 3 since Sep 2011
Thanks: 0 given, 0 received

Hi @Nicolas11, V2 it is. Please help me, many thanks.

Attached Thumbnails
Click image for larger version

Name:	1.jpg
Views:	81
Size:	95.8 KB
ID:	92586  
Reply With Quote
 
(login for full post details)
  #28 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

This problem on EconomicEventsDownloader is due to the fact that ForexFactory totally modified the underlying HTML format of its pages.

Nicolas

Visit my futures io Trade Journal Reply With Quote
 
(login for full post details)
  #29 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

Enclosed please find a new version (v3) of EconomicEventsDownloader.jar which addresses the new way Forex Factory formats its calendar (underlying HTML).

As for previous versions, the enclosed ZIP also contains source code. This source code is useless for the execution of EconomicEventsDownloader.jar. It is just given as a reference if, for any reason (for instance: security), you prefer to review the code and compile yourself the .jar file.

I have not tested it. I mean... it works, but I have not made deep tests in order to check that the output files fully correspond to the content of Forex Factory calendar. Please check it if you want to use it.

Nicolas

Attached Files
Register to download File Type: zip EconomicEventsDownloader_v3.zip (25.9 KB, 31 views)
Visit my futures io Trade Journal Reply With Quote
 
(login for full post details)
  #30 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

Enclosed please find a new version (v4) of EconomicEventsDownloader.jar which addresses the new way Forex Factory formats its calendar (underlying HTML).

As for previous versions, the enclosed ZIP also contains source code. This source code is useless for the execution of EconomicEventsDownloader.jar. It is just given as a reference if, for any reason (for instance: security), you prefer to review the code and compile yourself the .jar file.

I have not tested it. I mean... it works, but I have not made deep tests in order to check that the output files fully correspond to the content of Forex Factory calendar. Please check it if you want to use it.

Nicolas

Attached Files
Register to download File Type: zip EconomicEventsDownloader_v4.zip (26.1 KB, 28 views)
Visit my futures io Trade Journal Reply With Quote
The following 2 users say Thank You to Nicolas11 for this post:
 
(login for full post details)
  #31 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

@Jura informed me that v4 was not downloading events which happen at the same time as the previous event. It was due to another change in the structure of Forex Factory calendar.

Enclosed please find a new version (v5) of EconomicEventsDownloader.jar which corrects this issue.

As for previous versions, the enclosed ZIP also contains source code. This source code is useless for the execution of EconomicEventsDownloader.jar. It is just given as a reference if, for any reason (for instance: security), you prefer to review the code and compile yourself the .jar file.

I have not tested it. I mean... it works, but I have not made deep tests in order to check that the output files fully correspond to the content of Forex Factory calendar. Please check it if you want to use it.

Nicolas

Attached Files
Register to download File Type: zip EconomicEventsDownloader_v5.zip (26.2 KB, 57 views)
Visit my futures io Trade Journal Reply With Quote
The following 2 users say Thank You to Nicolas11 for this post:
 
(login for full post details)
  #32 (permalink)
Cotswolds UK
 
Experience: Intermediate
Platform: NT7, Multicharts
Broker: Mirus,Amp,ZenFire
Trading: Fdax
 
DarrenH's Avatar
 
Posts: 64 since Mar 2010
Thanks: 95 given, 23 received

Hi Jura

I placed the .dll file in C:\Program Files\TS Support\MultiCharts64, but i seem to still get the error.

IS it a 64 bit MC thing or maybe i am doing something wrong.

OK i had the 32bit file all ok thanks

Many Thanks

DarrenH


Jura View Post
You should place the .DLL file in the MultiCharts directory, not the folder itself since then MultiCharts can't find it.

Like this:



Let us know how that goes.


Reply With Quote
 
(login for full post details)
  #33 (permalink)
London
 
Experience: Beginner
Platform: MultiCharts
 
Posts: 240 since Nov 2010
Thanks: 10 given, 22 received

Is it possible load more historical data and have a time clock count down to economic event and a forecast from
Forex Factory
or fxcm website?

Why this nice tool is not native included in mc?

Reply With Quote
 
(login for full post details)
  #34 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

Hi @bomberone1

I am (was) in charge of the Java part for downloading, so I will only answer to "Is it possible load more historical data" question.

When previous versions of the tool were designed, downloading data from ForexFactory was only possible back to 2009. Now, it seems OK back to 2007.

So, enclosed please find a new version (v5.1) of EconomicEventsDownloader.jar which downloads back to 2007 (instead of 2009 in v5). It is the only change.

As for previous versions, the enclosed ZIP also contains source code. This source code is useless for the execution of the jar file. It is just given as a reference if, for any reason (for instance: security), you prefer to review the code and compile yourself the .jar file.

I have not tested it. I mean... it works, but I have not made deep tests in order to check that the output files fully correspond to the content of Forex Factory calendar. Please check it if you want to use it.

Nicolas

Attached Files
Register to download File Type: zip EconomicEventsDownloader_v5.1.zip (26.3 KB, 104 views)
Visit my futures io Trade Journal Reply With Quote
The following 6 users say Thank You to Nicolas11 for this post:
 
(login for full post details)
  #35 (permalink)
Belgium
 
Experience: Advanced
Platform: SaxoTrader
Broker: SaxoBank
Trading: ESTX
 
Posts: 292 since Dec 2009
Thanks: 243 given, 110 received

Fantastic tool. Wish there was an equivalent for NinjaTrader for economic news filtering during backtests.
It can definitely help to stay clear of some unwanted drawdowns on some markets.

Reply With Quote
The following 2 users say Thank You to SARdynamite for this post:
 
(login for full post details)
  #36 (permalink)
Site Administrator
Swing Trader
Data Scientist & DevOps
Manta, Ecuador
 
Experience: Advanced
Platform: My own custom solution
Trading: Emini Futures
 
Big Mike's Avatar
 
Posts: 49,412 since Jun 2009
Thanks: 32,068 given, 96,718 received


SARdynamite View Post
Fantastic tool. Wish there was an equivalent for NinjaTrader for economic news filtering during backtests.
It can definitely help to stay clear of some unwanted drawdowns on some markets.

Start a separate thread for NinjaTrader. I know users have created such a thing, @MWinfrey I believe for one. Also a simple test for if (Time[0] == Time[1]) will help to not trade during news events because for non-time based bars (ie: range bars) they will move quickly with identical timestamps in NT, and you can know to not trade under that circumstance.

Mike

We're here to help -- just ask

For the best trading education, watch our webinars
Searching for trading reviews? Review this list

Follow us on Twitter, YouTube, and Facebook

Support our community as an Elite Member:
https://futures.io/elite/
Follow me on Twitter Visit my futures io Trade Journal Reply With Quote
The following 2 users say Thank You to Big Mike for this post:
 
(login for full post details)
  #37 (permalink)
near Paris, France
 
Experience: Beginner
Platform: -
Trading: -
 
Nicolas11's Avatar
 
Posts: 1,071 since Aug 2011
Thanks: 2,232 given, 1,750 received

For completeness purpose, enclosed please find documentation for the Java tool which downloads economic events from Forex Factory.

Nicolas

Attached Thumbnails
The Economic Events Collection for MultiCharts-economic-events-downloader-v.5.1-documentation.pdf  
Visit my futures io Trade Journal Reply With Quote
The following 2 users say Thank You to Nicolas11 for this post:
 
(login for full post details)
  #38 (permalink)
Miami, FL / USA
 
Experience: Intermediate
Platform: MultiCharts
Trading: Futures, Forex
 
Posts: 14 since Feb 2013
Thanks: 0 given, 2 received

there seems to be a few examples of this using future news events. I am trying to create an indicator that plots historical events by showing it as a 0 for no news on the bar or 1 for news on that bar. i am using EE.GetHistoricalEvents but seem to be having all sorts of issues. could someone post a simple example of this in indicator form and not as some pop up. I am doing this because I want to use it in back testing.

thanks

Reply With Quote
 
(login for full post details)
  #39 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received


ausstone View Post
could someone post a simple example of this in indicator form and not as some pop up. I am doing this because I want to use it in back testing.

See the code below, which highlights economic events with an arrow and text. It's not 'production ready' (and therefore not "officially" published), but should give you more than enough to start with:

 
Code
Inputs:
	NameOfList("myHistList"),
	RegionsToKeep("EUR;USD;GBP"),
	ChopUpStrings(False),
	Ticks_OffSet(8),
	HighImpact_Color(Red),
	MediumImpact_Color(yellow),
	LowImpact_Color(cyan),
	DisplayArrow(True),
	Arrow_Size(5),
	DisplayLine(True),
	Line_Width(1),
	Line_Style(2),
	DisplayText(True),
	Text_FontSize(10),				
	Text_FontName("Lucida Sans Typewriter"),
	Text_FontColor(white);

Variables:
	tickOffSet( Ticks_OffSet * MinMove), //(Power(10, Round(Log(PriceScale) / Log(10), 0)) / MinMove) ),
	tickSize(MinMove / PriceScale), 
	dtEconEvent(0), prevDtEconEvent(0), dtNextBar(0), dtPrevBar(0), indexNumber(1),
	firstDate(0), firstTime(0), arrowID(0), textID(0), tlID(0), loopDoneForBar(False), impactOfEvent(0),
	listLength(0),
	x(0), y(0), z(0);

if (CurrentBar = 1) then begin 
	 firstDate = Date;
	 firstTime = Time_s;
end;

Arrays:
	barPrice[](0), barDT[](0), barPriceLow[](0);

once cleardebug;

// Collect data
if (BarStatus(1) = 2) then begin 
	x = Array_GetMaxIndex(barPrice);
	
	Array_SetMaxIndex(barPrice, x + 1);
	Array_SetMaxIndex(barDT, x + 1);
	Array_SetMaxIndex(barPriceLow, x + 1);
	
	barPrice[x+1]  	= Highest(High, 10);  //High;
	
	if (x > 10) then 
		barPrice[x+1-10] 	= Highest(High, 20);
	
	barDT[x+1] 			= ELDateToDateTime(Date) + ELTimeToDateTime_s(Time_s);
	barPriceLow[x+1]	= Low - (MinMove * 2);
	
end; //: Data collection


if (LastBarOnChart_s = True) and (BarStatus(1) = 2) and (GetAppInfo(aiRealTimeCalc) = 0) then begin 

	// Generate economic events list
	once begin 
	
		value1 = EE.GetHistoricalEvents(NameOfList, firstDate, Date);
//		value1 = EE.GetFutureEvents(NameOfList);
		value1 = EE.KeepTimeRange(NameOfList, SessionStartTime(0, DayOfWeek(Date)), SessionEndTime(0, DayOfWeek(Date)));
		value1 = EE.KeepRegions(NameOfList, RegionsToKeep);			// Only keep the specified regions in the list
		value1 = EE.RemoveImpact(NameOfList, 0);							// Remove all events with impact 0 (i.e. bank holiday)
	
		// Note: uncomment the line below to see which Economic Events are in the list after the filtering functions. (For debugging purposes)
//		EE.PrintToOutputLog(NameOfList); 
	end;

	Print("Lengt of bar array: ", array_getmaxindex(barPrice), "  and barDt: ", array_getmaxindex(barDT));
	
	dtEconEvent 	= EE.DateTimeOfEvent(NameOfList, indexNumber);	
	listLength 		= EE.GetMaxIndex(NameOfList);
	
	z = 1;
	y = 1;
	value1 = 1;
	value2 = 1;
	
	// Loop through data
	for x = 1 to Array_GetMaxIndex(barDT) - 1 begin 
	
		// if there are multiple economic events on this time
		for z = 0 to 9 begin
		
			if (IntPortion(barDT[x]) = IntPortion(dtEconEvent)) and (barDT[x-1] < dtEconEvent) and (barDT[x+1] > dtEconEvent) then begin 
			
				Print("PrevBar: ", DateTimeToStr(barDT[x-1]), " Event: ", DateTimeToStr(dtEconEvent), "  next bar: ", DateTimeToStr(barDT[x+1]));
				Print(Spaces(2), "Date of event: ", FormatDate("dd-MM-yy", ELDateToDateTime(EE.DateList(NameOfList, indexNumber))),
						"  Time of event: ", FormatTime("HH:mm:ss", ELTimeToDateTime(EE.TimeList(NameOfList, indexnumber))),
						"  name of event: ", EE.EventList(NameOfList, indexNumber));
						
				// Plot
				if (z = 0) then begin 
					
					if (DisplayText = True) then
				
						textID = Text_New_s(EE.DateList(NameOfList, indexNumber), 
									EE.TimeList(NameOfList, indexNumber) * 100,
									barPrice[x] + (tickSize * 2) + Arrow_Size, 
									IffString(ChopUpStrings = True, 
										StrChopUp(Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")),
										Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")
									));
					
					if (DisplayArrow = True) then 
					
						arrowID = Arw_New_s(EE.DateList(NameOfList, indexNumber), 
													EE.TimeList(NameOfList, indexNumber) * 100,
													barPrice[x], True);
					
					if (DisplayLine = True) then 							
					 	tlID = TL_New_s(EE.DateList(NameOfList, indexNumber),
					 						EE.TimeList(nameOfList, indexNumber) * 100,
					 						barPriceLow[x],
					 						EE.DateList(NameOfList, indexNumber),
					 						EE.TimeList(nameOfList, indexNumber) * 100,
					 						barPriceLow[x] * 0.85);
					 		
			 									
				end //: z = 0
				
				else if (DisplayText = True) then
					value1 = Text_SetString(textID, Text(Text_GetString(textID), NewLine, "&", NewLine,
								IffString(ChopUpStrings = True,
									StrChopUp(Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")),
									Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")"))	
								));
				
				// Formatting
				value6 = Text_SetSize(textID, Text_FontSize);
				value6 = Text_SetFontName(textID, Text_FontName);
				value6 = Text_SetStyle(textID, 0, 1);
				value6 = Text_SetColor(textID, Text_FontColor);
				
				value7 = Arw_SetSize(arrowID, Arrow_Size);
				
				value8 = TL_SetStyle(tlID, Line_Style);
				value8 = TL_SetSize(tlID, Line_Width);
				
				impactOfEvent = EE.ImpactList(NameOfList, indexNumber);
				
				switch (impactOfEvent) begin 
				
					case 1: 				// low impact
						value5 = Arw_SetColor(arrowID, LowImpact_Color);
						value5 = TL_SetColor(tlID, LowImpact_Color);
					
					case 2:				// medium
						value5 = Arw_SetColor(arrowID, MediumImpact_Color);
						value5 = TL_SetColor(tlID, MediumImpact_Color);
					
					case 3:				// high
						value5 = Arw_SetColor(arrowID, HighImpact_Color);
						value5 = TL_SetColor(tlID, HighImpact_Color);
				
				end; //: ImpactOfEvent switch

				indexNumber	= indexNumber + 1;
				
				dtEconEvent = IFF(indexNumber > listLength, 9999999, EE.DateTimeOfEvent(NameOfList, indexNumber));
				
				Print(Spaces(3), "Next econ event = ", DateTimeToStr(dtEconEvent));
				
//				value2 = value2 + 1;
			
			end else if (IntPortion(barDT[x]) > IntPortion(dtEconEvent)) then begin 
			
				Print("BarDT: ", DateTimeToStr(BarDT[x]), " econ event: ", DateTimeToStr(dtEconEvent), " - happened on a market closed day");
				
				indexNumber	= indexNumber + 1;
				
				dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);
			
//				value1 = value1 + 1;
			end;
	
		end; //: z loop
	end; //: x loop
	
//	Print("How many economic events missed? ", value1);
//	Print("How many economic events plotted? ", value2);

		loopDoneForBar = False;
		
		while (loopDoneForBar = False) begin 
		
			// If the economic event doesn't happen on this day -> skip
			// that way, when the market is closed when economic events happened, the list moves on
			if (IntPortion(barDT[x]) > IntPortion(dtEconEvent)) then begin 
			
				y = y + 1;
				
				Print(Spaces(2), "How many days skipped? ", NumToStr(y, 0));
				
				Print(Spaces(4), "Date: ", FormatDate("dd-MM-yyyy", barDT[x]), 
					"  event date: ", FormatDate("dd-MM-yyyy", dtEconEvent));
			
				indexNumber	= indexNumber + 1;
				
				if (indexNumber <= listLength) then begin
					dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);
//					Print("indexnum: ", NumToStr(indexNumber, 0));
				end;
				
				loopDoneForBar = True;
						
			end else 
			
			if (barDT[x-1] < dtEconEvent) and (barDT[x+1] > dtEconEvent) then begin 
			
				z = z + 1;
							
				Print("How many events are there according to the code? ", NumToStr(z, 0), 
						"  And what is x? ", NumToStr(x, 0));
			
//				Print(Spaces(2), "dt: ", NumToStr(dtEconEvent, 10), " indexNumber: ", indexNumber,
//					" Date: ", FormatDate("dd-MM-yyyy", dtEconEvent), "  time: ", ToTime_DT(dtEconEvent));
				
				// Draw text & arrows
				textID = Text_New_s(EE.DateList(NameOfList, indexNumber), EE.TimeList(NameOfList, indexNumber) * 100, barPrice[x] + tickOffSet,
									Text(EE.EventList(NameOfList, indexNumber), "(", EE.RegionList(NameOfList, indexNumber), ")"));
				
				arrowID = Arw_New_s(EE.DateList(NameOfList, indexNumber), EE.TimeList(NameOfList, indexNumber),
				 					barPrice[x] + 0.33 * tickOffSet, True);				
			
				indexNumber	= indexNumber + 1;
				dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);
				
				if (dtEconEvent = prevDtEconEvent) then 
					loopDoneForBar = False 
				else 
					loopDoneForBar = True;
				
			end else 
				loopDoneForBar = True;
		end;
		//prevDtEconEvent = dtEconEvent;
	
	

	
	Print("length of list? : ", EE.GetMaxIndex(NameOfList));

end; //: LastBarOnChart_s check

Started this thread Reply With Quote
The following user says Thank You to Jura for this post:
 
(login for full post details)
  #40 (permalink)
Nitra Slovakia
 
 
Posts: 3 since Feb 2014
Thanks: 2 given, 0 received


Jura View Post
See the code below, which highlights economic events with an arrow and text. It's not 'production ready' (and therefore not "officially" published), but should give you more than enough to start with:

 
Code
Inputs:
	NameOfList("myHistList"),
	RegionsToKeep("EUR;USD;GBP"),
	ChopUpStrings(False),
	Ticks_OffSet(8),
	HighImpact_Color(Red),
	MediumImpact_Color(yellow),
	LowImpact_Color(cyan),
	DisplayArrow(True),
	Arrow_Size(5),
	DisplayLine(True),
	Line_Width(1),
	Line_Style(2),
	DisplayText(True),
	Text_FontSize(10),				
	Text_FontName("Lucida Sans Typewriter"),
	Text_FontColor(white);

Variables:
	tickOffSet( Ticks_OffSet * MinMove), //(Power(10, Round(Log(PriceScale) / Log(10), 0)) / MinMove) ),
	tickSize(MinMove / PriceScale), 
	dtEconEvent(0), prevDtEconEvent(0), dtNextBar(0), dtPrevBar(0), indexNumber(1),
	firstDate(0), firstTime(0), arrowID(0), textID(0), tlID(0), loopDoneForBar(False), impactOfEvent(0),
	listLength(0),
	x(0), y(0), z(0);

if (CurrentBar = 1) then begin 
	 firstDate = Date;
	 firstTime = Time_s;
end;

Arrays:
	barPrice[](0), barDT[](0), barPriceLow[](0);

once cleardebug;

// Collect data
if (BarStatus(1) = 2) then begin 
	x = Array_GetMaxIndex(barPrice);
	
	Array_SetMaxIndex(barPrice, x + 1);
	Array_SetMaxIndex(barDT, x + 1);
	Array_SetMaxIndex(barPriceLow, x + 1);
	
	barPrice[x+1]  	= Highest(High, 10);  //High;
	
	if (x > 10) then 
		barPrice[x+1-10] 	= Highest(High, 20);
	
	barDT[x+1] 			= ELDateToDateTime(Date) + ELTimeToDateTime_s(Time_s);
	barPriceLow[x+1]	= Low - (MinMove * 2);
	
end; //: Data collection


if (LastBarOnChart_s = True) and (BarStatus(1) = 2) and (GetAppInfo(aiRealTimeCalc) = 0) then begin 

	// Generate economic events list
	once begin 
	
		value1 = EE.GetHistoricalEvents(NameOfList, firstDate, Date);
//		value1 = EE.GetFutureEvents(NameOfList);
		value1 = EE.KeepTimeRange(NameOfList, SessionStartTime(0, DayOfWeek(Date)), SessionEndTime(0, DayOfWeek(Date)));
		value1 = EE.KeepRegions(NameOfList, RegionsToKeep);			// Only keep the specified regions in the list
		value1 = EE.RemoveImpact(NameOfList, 0);							// Remove all events with impact 0 (i.e. bank holiday)
	
		// Note: uncomment the line below to see which Economic Events are in the list after the filtering functions. (For debugging purposes)
//		EE.PrintToOutputLog(NameOfList); 
	end;

	Print("Lengt of bar array: ", array_getmaxindex(barPrice), "  and barDt: ", array_getmaxindex(barDT));
	
	dtEconEvent 	= EE.DateTimeOfEvent(NameOfList, indexNumber);	
	listLength 		= EE.GetMaxIndex(NameOfList);
	
	z = 1;
	y = 1;
	value1 = 1;
	value2 = 1;
	
	// Loop through data
	for x = 1 to Array_GetMaxIndex(barDT) - 1 begin 
	
		// if there are multiple economic events on this time
		for z = 0 to 9 begin
		
			if (IntPortion(barDT[x]) = IntPortion(dtEconEvent)) and (barDT[x-1] < dtEconEvent) and (barDT[x+1] > dtEconEvent) then begin 
			
				Print("PrevBar: ", DateTimeToStr(barDT[x-1]), " Event: ", DateTimeToStr(dtEconEvent), "  next bar: ", DateTimeToStr(barDT[x+1]));
				Print(Spaces(2), "Date of event: ", FormatDate("dd-MM-yy", ELDateToDateTime(EE.DateList(NameOfList, indexNumber))),
						"  Time of event: ", FormatTime("HH:mm:ss", ELTimeToDateTime(EE.TimeList(NameOfList, indexnumber))),
						"  name of event: ", EE.EventList(NameOfList, indexNumber));
						
				// Plot
				if (z = 0) then begin 
					
					if (DisplayText = True) then
				
						textID = Text_New_s(EE.DateList(NameOfList, indexNumber), 
									EE.TimeList(NameOfList, indexNumber) * 100,
									barPrice[x] + (tickSize * 2) + Arrow_Size, 
									IffString(ChopUpStrings = True, 
										StrChopUp(Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")),
										Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")
									));
					
					if (DisplayArrow = True) then 
					
						arrowID = Arw_New_s(EE.DateList(NameOfList, indexNumber), 
													EE.TimeList(NameOfList, indexNumber) * 100,
													barPrice[x], True);
					
					if (DisplayLine = True) then 							
					 	tlID = TL_New_s(EE.DateList(NameOfList, indexNumber),
					 						EE.TimeList(nameOfList, indexNumber) * 100,
					 						barPriceLow[x],
					 						EE.DateList(NameOfList, indexNumber),
					 						EE.TimeList(nameOfList, indexNumber) * 100,
					 						barPriceLow[x] * 0.85);
					 		
			 									
				end //: z = 0
				
				else if (DisplayText = True) then
					value1 = Text_SetString(textID, Text(Text_GetString(textID), NewLine, "&", NewLine,
								IffString(ChopUpStrings = True,
									StrChopUp(Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")),
									Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")"))	
								));
				
				// Formatting
				value6 = Text_SetSize(textID, Text_FontSize);
				value6 = Text_SetFontName(textID, Text_FontName);
				value6 = Text_SetStyle(textID, 0, 1);
				value6 = Text_SetColor(textID, Text_FontColor);
				
				value7 = Arw_SetSize(arrowID, Arrow_Size);
				
				value8 = TL_SetStyle(tlID, Line_Style);
				value8 = TL_SetSize(tlID, Line_Width);
				
				impactOfEvent = EE.ImpactList(NameOfList, indexNumber);
				
				switch (impactOfEvent) begin 
				
					case 1: 				// low impact
						value5 = Arw_SetColor(arrowID, LowImpact_Color);
						value5 = TL_SetColor(tlID, LowImpact_Color);
					
					case 2:				// medium
						value5 = Arw_SetColor(arrowID, MediumImpact_Color);
						value5 = TL_SetColor(tlID, MediumImpact_Color);
					
					case 3:				// high
						value5 = Arw_SetColor(arrowID, HighImpact_Color);
						value5 = TL_SetColor(tlID, HighImpact_Color);
				
				end; //: ImpactOfEvent switch

				indexNumber	= indexNumber + 1;
				
				dtEconEvent = IFF(indexNumber > listLength, 9999999, EE.DateTimeOfEvent(NameOfList, indexNumber));
				
				Print(Spaces(3), "Next econ event = ", DateTimeToStr(dtEconEvent));
				
//				value2 = value2 + 1;
			
			end else if (IntPortion(barDT[x]) > IntPortion(dtEconEvent)) then begin 
			
				Print("BarDT: ", DateTimeToStr(BarDT[x]), " econ event: ", DateTimeToStr(dtEconEvent), " - happened on a market closed day");
				
				indexNumber	= indexNumber + 1;
				
				dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);
			
//				value1 = value1 + 1;
			end;
	
		end; //: z loop
	end; //: x loop
	
//	Print("How many economic events missed? ", value1);
//	Print("How many economic events plotted? ", value2);

		loopDoneForBar = False;
		
		while (loopDoneForBar = False) begin 
		
			// If the economic event doesn't happen on this day -> skip
			// that way, when the market is closed when economic events happened, the list moves on
			if (IntPortion(barDT[x]) > IntPortion(dtEconEvent)) then begin 
			
				y = y + 1;
				
				Print(Spaces(2), "How many days skipped? ", NumToStr(y, 0));
				
				Print(Spaces(4), "Date: ", FormatDate("dd-MM-yyyy", barDT[x]), 
					"  event date: ", FormatDate("dd-MM-yyyy", dtEconEvent));
			
				indexNumber	= indexNumber + 1;
				
				if (indexNumber <= listLength) then begin
					dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);
//					Print("indexnum: ", NumToStr(indexNumber, 0));
				end;
				
				loopDoneForBar = True;
						
			end else 
			
			if (barDT[x-1] < dtEconEvent) and (barDT[x+1] > dtEconEvent) then begin 
			
				z = z + 1;
							
				Print("How many events are there according to the code? ", NumToStr(z, 0), 
						"  And what is x? ", NumToStr(x, 0));
			
//				Print(Spaces(2), "dt: ", NumToStr(dtEconEvent, 10), " indexNumber: ", indexNumber,
//					" Date: ", FormatDate("dd-MM-yyyy", dtEconEvent), "  time: ", ToTime_DT(dtEconEvent));
				
				// Draw text & arrows
				textID = Text_New_s(EE.DateList(NameOfList, indexNumber), EE.TimeList(NameOfList, indexNumber) * 100, barPrice[x] + tickOffSet,
									Text(EE.EventList(NameOfList, indexNumber), "(", EE.RegionList(NameOfList, indexNumber), ")"));
				
				arrowID = Arw_New_s(EE.DateList(NameOfList, indexNumber), EE.TimeList(NameOfList, indexNumber),
				 					barPrice[x] + 0.33 * tickOffSet, True);				
			
				indexNumber	= indexNumber + 1;
				dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);
				
				if (dtEconEvent = prevDtEconEvent) then 
					loopDoneForBar = False 
				else 
					loopDoneForBar = True;
				
			end else 
				loopDoneForBar = True;
		end;
		//prevDtEconEvent = dtEconEvent;
	
	

	
	Print("length of list? : ", EE.GetMaxIndex(NameOfList));

end; //: LastBarOnChart_s check



Hello Jura
I compiled code in Multicharts but the chart does not show me anything.

Can you please advise where it can be wrong?

Reply With Quote
 
(login for full post details)
  #41 (permalink)
 
 
Posts: 2,225 since Apr 2013
Thanks: 406 given, 1,468 received

monexx,

did you download the Economic events before with the Java tool?

Regards,
ABCTG


monexx View Post
Hello Jura
I compiled code in Multicharts but the chart does not show me anything.

Can you please advise where it can be wrong?


Follow me on Twitter Reply With Quote
The following 2 users say Thank You to ABCTG for this post:
 
(login for full post details)
  #42 (permalink)
Nitra Slovakia
 
 
Posts: 3 since Feb 2014
Thanks: 2 given, 0 received


ABCTG View Post
monexx,

did you download the Economic events before with the Java tool?

Regards,
ABCTG


Yes, I downloaded it.
Upcoming economic events idicator works well.
This version for backtest published by Jura does not work .
It will not appear historical economic events on the chart .

Reply With Quote
 
(login for full post details)
  #43 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received


monexx View Post
Yes, I downloaded it.
Upcoming economic events idicator works well.
This version for backtest published by Jura does not work .
It will not appear historical economic events on the chart .

What have you tried so far, and when does the error occur?

Started this thread Reply With Quote
The following 2 users say Thank You to Jura for this post:
 
(login for full post details)
  #44 (permalink)
Nitra Slovakia
 
 
Posts: 3 since Feb 2014
Thanks: 2 given, 0 received

I turned off : Update on every tick
I compile the code in this form :

Inputs:
NameOfList("myHistList"),
RegionsToKeep("EUR;USD;GBP"),
ChopUpStrings(False),
Ticks_OffSet(8),
HighImpact_Color(Red),
MediumImpact_Color(yellow),
LowImpact_Color(cyan),
DisplayArrow(True),
Arrow_Size(5),
DisplayLine(True),
Line_Width(1),
Line_Style(2),
DisplayText(True),
Text_FontSize(10),
Text_FontName("Lucida Sans Typewriter"),
Text_FontColor(white);

Variables:
tickOffSet( Ticks_OffSet * MinMove), //(Power(10, Round(Log(PriceScale) / Log(10), 0)) / MinMove) ),
tickSize(MinMove / PriceScale),
dtEconEvent(0), prevDtEconEvent(0), dtNextBar(0), dtPrevBar(0), indexNumber(1),
firstDate(0), firstTime(0), arrowID(0), textID(0), tlID(0), loopDoneForBar(False), impactOfEvent(0),
listLength(0),
x(0), y(0), z(0);

if (CurrentBar = 1) then begin
firstDate = Date;
firstTime = Time_s;
end;

Arrays:
barPrice[](0), barDT[](0), barPriceLow[](0);

once cleardebug;

// Collect data
if (BarStatus(1) = 2) then begin
x = Array_GetMaxIndex(barPrice);

Array_SetMaxIndex(barPrice, x + 1);
Array_SetMaxIndex(barDT, x + 1);
Array_SetMaxIndex(barPriceLow, x + 1);

barPrice[x+1] = Highest(High, 10); //High;

if (x > 10) then
barPrice[x+1-10] = Highest(High, 20);

barDT[x+1] = ELDateToDateTime(Date) + ELTimeToDateTime_s(Time_s);
barPriceLow[x+1] = Low - (MinMove * 2);

end; //: Data collection


if (LastBarOnChart_s = True) and (BarStatus(1) = 2) and (GetAppInfo(aiRealTimeCalc) = 0) then begin

// Generate economic events list
once begin

value1 = EE.GetHistoricalEvents(NameOfList, firstDate, Date);
// value1 = EE.GetFutureEvents(NameOfList);
value1 = EE.KeepTimeRange(NameOfList, SessionStartTime(0, DayOfWeek(Date)), SessionEndTime(0, DayOfWeek(Date)));
value1 = EE.KeepRegions(NameOfList, RegionsToKeep); // Only keep the specified regions in the list
value1 = EE.RemoveImpact(NameOfList, 0); // Remove all events with impact 0 (i.e. bank holiday)

// Note: uncomment the line below to see which Economic Events are in the list after the filtering functions. (For debugging purposes)
// EE.PrintToOutputLog(NameOfList);
end;

Print("Lengt of bar array: ", array_getmaxindex(barPrice), " and barDt: ", array_getmaxindex(barDT));

dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);
listLength = EE.GetMaxIndex(NameOfList);

z = 1;
y = 1;
value1 = 1;
value2 = 1;

// Loop through data
for x = 1 to Array_GetMaxIndex(barDT) - 1 begin

// if there are multiple economic events on this time
for z = 0 to 9 begin

if (IntPortion(barDT[x]) = IntPortion(dtEconEvent)) and (barDT[x-1] < dtEconEvent) and (barDT[x+1] > dtEconEvent) then begin

Print("PrevBar: ", DateTimeToString(barDT[x-1]), " Event: ", DateTimeToString(dtEconEvent), " next bar: ", DateTimeToString(barDT[x+1]));
Print(Spaces(2), "Date of event: ", FormatDate("dd-MM-yy", ELDateToDateTime(EE.DateList(NameOfList, indexNumber))),
" Time of event: ", FormatTime("HH:mm:ss", ELTimeToDateTime(EE.TimeList(NameOfList, indexnumber))),
" name of event: ", EE.EventList(NameOfList, indexNumber));

// Plot
if (z = 0) then begin

if (DisplayText = True) then

textID = Text_New_s(EE.DateList(NameOfList, indexNumber),
EE.TimeList(NameOfList, indexNumber) * 100,
barPrice[x] + (tickSize * 2) + Arrow_Size,
IffString(ChopUpStrings = True,
StrChopUp(Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")),
Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")
));

if (DisplayArrow = True) then

arrowID = Arw_New_s(EE.DateList(NameOfList, indexNumber),
EE.TimeList(NameOfList, indexNumber) * 100,
barPrice[x], True);

if (DisplayLine = True) then
tlID = TL_New_s(EE.DateList(NameOfList, indexNumber),
EE.TimeList(nameOfList, indexNumber) * 100,
barPriceLow[x],
EE.DateList(NameOfList, indexNumber),
EE.TimeList(nameOfList, indexNumber) * 100,
barPriceLow[x] * 0.85);


end //: z = 0

else if (DisplayText = True) then
value1 = Text_SetString(textID, Text(Text_GetString(textID), NewLine, "&", NewLine,
IffString(ChopUpStrings = True,
StrChopUp(Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")")),
Text(EE.EventList(NameOfList, indexNumber), " (", EE.RegionList(NameOfList, indexNumber), ")"))
));

// Formatting
value6 = Text_SetSize(textID, Text_FontSize);
value6 = Text_SetFontName(textID, Text_FontName);
value6 = Text_SetStyle(textID, 0, 1);
value6 = Text_SetColor(textID, Text_FontColor);

value7 = Arw_SetSize(arrowID, Arrow_Size);

value8 = TL_SetStyle(tlID, Line_Style);
value8 = TL_SetSize(tlID, Line_Width);

impactOfEvent = EE.ImpactList(NameOfList, indexNumber);

switch (impactOfEvent) begin

case 1: // low impact
value5 = Arw_SetColor(arrowID, LowImpact_Color);
value5 = TL_SetColor(tlID, LowImpact_Color);

case 2: // medium
value5 = Arw_SetColor(arrowID, MediumImpact_Color);
value5 = TL_SetColor(tlID, MediumImpact_Color);

case 3: // high
value5 = Arw_SetColor(arrowID, HighImpact_Color);
value5 = TL_SetColor(tlID, HighImpact_Color);

end; //: ImpactOfEvent switch

indexNumber = indexNumber + 1;

dtEconEvent = IFF(indexNumber > listLength, 9999999, EE.DateTimeOfEvent(NameOfList, indexNumber));

Print(Spaces(3), "Next econ event = ", DateTimeToString(dtEconEvent));

// value2 = value2 + 1;

end else if (IntPortion(barDT[x]) > IntPortion(dtEconEvent)) then begin

Print("BarDT: ", DateTimeToString(BarDT[x]), " econ event: ", DateTimeToString(dtEconEvent), " - happened on a market closed day");

indexNumber = indexNumber + 1;

dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);

// value1 = value1 + 1;
end;

end; //: z loop
end; //: x loop

// Print("How many economic events missed? ", value1);
// Print("How many economic events plotted? ", value2);

loopDoneForBar = False;

while (loopDoneForBar = False) begin

// If the economic event doesn't happen on this day -> skip
// that way, when the market is closed when economic events happened, the list moves on
if (IntPortion(barDT[x]) > IntPortion(dtEconEvent)) then begin

y = y + 1;

Print(Spaces(2), "How many days skipped? ", NumToStr(y, 0));

Print(Spaces(4), "Date: ", FormatDate("dd-MM-yyyy", barDT[x]),
" event date: ", FormatDate("dd-MM-yyyy", dtEconEvent));

indexNumber = indexNumber + 1;

if (indexNumber <= listLength) then begin
dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);
// Print("indexnum: ", NumToStr(indexNumber, 0));
end;

loopDoneForBar = True;

end else

if (barDT[x-1] < dtEconEvent) and (barDT[x+1] > dtEconEvent) then begin

z = z + 1;

Print("How many events are there according to the code? ", NumToStr(z, 0),
" And what is x? ", NumToStr(x, 0));

// Print(Spaces(2), "dt: ", NumToStr(dtEconEvent, 10), " indexNumber: ", indexNumber,
// " Date: ", FormatDate("dd-MM-yyyy", dtEconEvent), " time: ", ToTime_DT(dtEconEvent));

// Draw text & arrows
textID = Text_New_s(EE.DateList(NameOfList, indexNumber), EE.TimeList(NameOfList, indexNumber) * 100, barPrice[x] + tickOffSet,
Text(EE.EventList(NameOfList, indexNumber), "(", EE.RegionList(NameOfList, indexNumber), ")"));

arrowID = Arw_New_s(EE.DateList(NameOfList, indexNumber), EE.TimeList(NameOfList, indexNumber),
barPrice[x] + 0.33 * tickOffSet, True);

indexNumber = indexNumber + 1;
dtEconEvent = EE.DateTimeOfEvent(NameOfList, indexNumber);

if (dtEconEvent = prevDtEconEvent) then
loopDoneForBar = False
else
loopDoneForBar = True;

end else
loopDoneForBar = True;
end;
//prevDtEconEvent = dtEconEvent;




Print("length of list? : ", EE.GetMaxIndex(NameOfList));

end; //: LastBarOnChart_s check




I got this error message : attached screenshot

Attached Thumbnails
Click image for larger version

Name:	EE for backtest.png
Views:	101
Size:	260.2 KB
ID:	138018  
Reply With Quote
 
(login for full post details)
  #45 (permalink)
Melbourne, Australia
 
Experience: Intermediate
Platform: NT8, Multicharts,Sierra
Broker: CQG, IB
Trading: YM,CL,GC,6E,6J
 
Posts: 97 since Mar 2013
Thanks: 83 given, 60 received

Hi Jura and Nicolas,
I've been using your wonderful tool for months now.

However, I ran into my first forexfactory problem today - see pic below.
Do you think they've changed their settings again ?

EDIT - IGNORE THIS, IT'S BACK UP AND RUNNING AGAIN

Attached Thumbnails
Click image for larger version

Name:	Screen Shot 2014-11-30 at 10.02.22 am.png
Views:	68
Size:	56.0 KB
ID:	167446  
Reply With Quote
 
(login for full post details)
  #46 (permalink)
Cape Town
 
 
Posts: 6 since Mar 2012
Thanks: 4 given, 0 received

Hi Guys I keep getting the error STD Exception: underflow/overflow/range error??? Anyone know how to fix it??

Reply With Quote
 
(login for full post details)
  #47 (permalink)
Boston, MA
 
Experience: Intermediate
Platform: MultiCharts, TradeStation, NinjaTrader, ThinkorSwim
Trading: ES
 
Posts: 26 since Jul 2011
Thanks: 16 given, 13 received


Jura View Post
Upcoming Economic Events indicator

This indicator plots a text box on the chart with the upcoming economic events:


In this screenshot, taken on 15:56 local time (Western-Europe), you can see that Geithner was about to speak in 4 minutes (a Medium impact event) and the business inventories were also announced in four minutes.

The indicator has the following settings:


Most of these settings are self-explanatory. The 'TicksOffSetBottom' is the number of ticks you want the text box be displayed above the lowest value on the price scale. The 'RecalcAfter' is the number of seconds the box is updated - this is included to prevent excessive updating from MultiCharts to keep everything running smoothing.

Important note: You'll need the Economic Events Collection for MultiCharts (see first post in this thread and download here) to work with this indicator.

This indicator can be downloaded here.

I'm a little bit confused by this: I only see functions in the download package, but no "indicator." What am I missing here? Thanks...

Reply With Quote
 
(login for full post details)
  #48 (permalink)
The Netherlands
 
Experience: None
Platform: MultiCharts, TradingView
Trading: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 686 received


tortoise View Post
I'm a little bit confused by this: I only see functions in the download package, but no "indicator." What am I missing here? Thanks...

This is somewhat ironic. My post that you quote has a sentence that read: "This indicator can be downloaded here.". Did you click on that link? It takes me to the download file (.pla) with the indicator. Does the .pla file not work for you?

Started this thread Reply With Quote
 
(login for full post details)
  #49 (permalink)
Phoenix, Arizona
 
 
Posts: 1 since Oct 2011
Thanks: 0 given, 0 received

I just love the Economic Events tools. They are indispensable!

Starting about March 29, the downloader gives an error message:
Problem for identification of hour in: <td class="calendar__cell calendar__time time">1:30am</td>
main.ParseStringAndSave.parseStringAndSaveToFile(ParseStringAndSave.java:165)

Probably Forex Factory changed the calendar format again.

Could Nicolas11 fix the Java or whoever is officially maintaining the source code?

Thank you, very much appreciate this effort.

Reply With Quote
 
(login for full post details)
  #50 (permalink)
Hamburg, Germany
 
 
Posts: 5 since Oct 2010
Thanks: 1 given, 0 received


rrams View Post
Starting about March 29, the downloader gives an error message:
Problem for identification of hour in: <td class="calendar__cell calendar__time time">1:30am</td>
main.ParseStringAndSave.parseStringAndSaveToFile(ParseStringAndSave.java:165)

Problem for identification of hour in: <td class="calendar__cell calendar__time time">1:30am</td>
main.ParseStringAndSave.parseStringAndSaveToFile(ParseStringAndSave.java:165)
main.Main.step3_proceedForFutureEconomicEvents(Main.java:134)
main.Main.main(Main.java:319)

Same Problem here, any help how to fix this problem would be apreciated.
Thank you

Reply With Quote
 
(login for full post details)
  #51 (permalink)
Hamburg, Germany
 
 
Posts: 5 since Oct 2010
Thanks: 1 given, 0 received

I only can assume this problem is related to time change over to summer time.
???

Reply With Quote
 
(login for full post details)
  #52 (permalink)
Hamburg, Germany
 
 
Posts: 5 since Oct 2010
Thanks: 1 given, 0 received

For members who still interested to fix the problem with EconomicEvents Downloader go to MultiCharts forum

Forum index » MultiCharts » User Contributed Studies and Indicator Library
»The Economic Events Collection for MultiCharts

in them tread MultiCharts community member has a version to bypass this problem, he simly create the new txt files.
Sorry I can't post the direct link.

Reply With Quote


futures io Trading Community Platforms and Indicators MultiCharts > The Economic Events Collection for MultiCharts


Last Updated on May 2, 2016


Upcoming Webinars and Events
 

NinjaTrader Indicator Challenge!

Ongoing
 

Finding Trading Opportunities Using Profile Charts w/Tradovate

Jan 28
 

Journal Challenge!

February
 

Battlestations!

March
     



Copyright © 2021 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts