Forex Factory (https://www.forexfactory.com/forum.php)
-   Trading Systems (https://www.forexfactory.com/forumdisplay.php?f=71)
-   -   Red News Hedge Trading + EA (https://www.forexfactory.com/showthread.php?t=565676)

MathTrader7 Nov 11, 2015 3:44pm | Post# 1

Red News Hedge Trading + EA
 
4 Attachment(s)
This trading strategy is based on taking advantage of high volatility in the market due to high impact red news. In this strategy, we open two trades on two different currency pairs which are known to be correlated (positively or negatively). For example, we open Long positions on both EURUSD and USDJPY a few seconds before a high impact red news in the hope of earning some pips from any imbalance in the basket. I have written an EA that makes it easier to trade this strategy. Attach the EA to one of currency pairs' chart (for example, EURUSD), and enter the hedge currency pair symbol (for example, USDJPY) in the input settings of the EA. There are four buttons to open positions,

1. Buy/Sell: the EA opens a Buy position on the attached chart, and a Sell position on the hedge currency pair.
2. Sell/Buy: the EA opens a Sell position on the attached chart, and a Buy position on the hedge currency pair.
3. Buy/Buy: the EA opens Buy positions on both currency pairs.
4. Sell/Sell: the EA opens Sell positions on both currency pairs.

and there are three buttons to close the basket manually. You can specify the net take profit (in money, not pips!) in the input settings of the EA.

Positively Correlated Symbols
For a pair of symbols that are positively correlated (such as AUDUSD and AUDCAD), use either Buy/Sell or Sell/Buy button.

Negatively Correlated Symbols
For a pair of symbols that are negatively correlated (such as EURUSD and USDJPY), use either Buy/Buy or Sell/Sell button.

Forex Correlation Table
Here is a website where you can find a Forex correlation table,

https://www.mataf.net/en/forex/tools/correlation

for example,
AUDCAD ~ EURAUD
AUDJPY ~ AUDNZD
CADJPY ~ AUDJPY
...

How I trade with this strategy:
1. Choose a high impact red news of a major currency, for example AUD.
2. Choose two other major currencies to pair with AUD such that the absolute correlation of two pairs is greater than 0.5, for example AUDUSD and AUDCAD.
3. A few minutes before the news release time, look at a currency strength meter to observe which of above two currencies (USD or CAD) is more powerful.
4. Select a trade button according to both the sign of correlation (this can be automatically done by the EA for you), and the strongest currency you identified in the previous step.
See an example here:
https://www.forexfactory.com/showthr...4#post10532124

A Few Currency Strength Meter Indicators
1. csDash (currency strength meter)
2. Recent Strength indicator
3. Currency Strength Indicator

How to load history data for hedge symbols?
In order to load history data of hedge symbols, you can follow the steps below:
1. Hit <F2> key to bring up History Center window.
2. Select the symbol (for example, EURUSD).
3. Click on <Download> button.
4. Repeat 1 to 3 for all symbols you want to load history data.

Thread Rules:
1. In this thread we discuss only the strategy and the EA presented here. I will IGNORE anyone who writes any irrelevant post in this thread.
2. TBD.

--- Update 2019-01-31 ---
Version 1.75 of the EA released. This version is compiled with MT4 build 1170 (bug fixes). Click to Enlarge

Name: EURUSDH1.png
Size: 35 KB
MathTrader7_NewsHedgeEA.ex4
Input settings description:

1. Select Auto Time Based Action:

- Auto Trade Disabled (default), This option disables auto time based trading.

- Buy/Buy: This option makes the EA to open BUY/BUY positions at Auto Action Time.

- Sell/Sell: This option makes the EA to open SELL/SELL positions at Auto Action Time.

- Buy/Sell: This option makes the EA to open BUY/SELL positions at Auto Action Time.

- Sell/Buy: This option makes the EA to open SELL/BUY positions at Auto Action Time.

2. Enter Auto Action Time (broker time):

- yyyy.mm.dd hh:mm:ss, for example 2015.11.19 14:29:30

- The EA opens two positions at this time according to Select Auto Time Based Action setting.

3. Auto Button Selection?

- If enabled, the EA hides irrelevant trade buttons according to the correlation value between two symbols.

4. Hedge Symbol:

- Enter hedge symbol as exactly as it appears on the market watch of your MT4 platform.

5. Net Take Profit (money):

- When net profit becomes greater than this value, the EA automatically closes both positions.

6. Net Stop Loss (money):

- When net profit becomes less than negative of this value, the EA automatically closes both positions.

7. Equalize Pips?

- If enabled, the lot size of trading two positions will be recalculated such that one pip of both symbols will be (approximately) worth equal (see Post 104).

- If disabled, the EA opens two positions with the user specified lot size.

8.1 Lot Size: 0.1 (default)

8.2 Hedge Lot Size: 0.1 (default)

9. Slippage (points): 30 (default)

10. Magic Number: 1122 (default)

- If you want to use the EA on the same symbol twice or more, you have to assign different magic numbers. Otherwise, leave it default.


== Update 2019-02-27 ======================
Ver. 1.80: An Experimental Currency Strength Meter is added to the EA.
Click to Enlarge

Name: EURUSDM1.png
Size: 39 KB
MathTrader7_NewsHedgeEA_CSM.ex4

====================================
How to install this EA on your MetaTrader4 Platform
For newbies, here is a video on youtube that shows how to install any EA on MetaTrader 4 platform in 5 easy steps

techlover Nov 11, 2015 11:50pm | Post# 2

Thank you for your Ea Math

have placed it on Usdjpy chart with EURUSD to hedge and clicked Buy/sell button , it opened 0.1 Usdjpy and 0.08 Eurusd

may i know why it opened 0.08 in EURUSD ? , will it calculate the perfect hedging lot size ?

MathTrader7 Nov 12, 2015 4:55am | Post# 3

Thank you for your Ea Math have placed it on Usdjpy chart with EURUSD to hedge and clicked Buy/sell button , it opened 0.1 Usdjpy and 0.08 Eurusd may i know why it opened 0.08 in EURUSD ? , will it calculate the perfect hedging lot size ?
You're welcome! :-)

And you're right! The EA calculates lots to equalize the worth of one point of both currency pairs. I uploaded a new version (v1.10) with an input to let the user enable/disable this function.

techlover Nov 12, 2015 5:04am | Post# 4

{quote} You're welcome! :-) And you're right! The EA calculates lots to equalize the worth of one point of both currency pairs. I uploaded a new version (v1.10) with an input to let the user enable/disable this function.
there is a Bug in Ea, its not closing at desired Profit

MathTrader7 Nov 12, 2015 5:10am | Post# 5

{quote} there is a Bug in Ea, its not closing at desired Profit
Please test v1.10, I optimized the close basket functionality to send order close command to the broker server as fast as possible.

mpradeep Nov 12, 2015 5:56am | Post# 6

Other than EU with UJ which will be the best pair?

MathTrader7 Nov 12, 2015 6:42am | Post# 7

Other than EU with UJ which will be the best pair?
For AUD red news, I trade AUDUSD and AUDCAD. Go for either BUY/SELL or SELL/BUY for this pair of symbols.
For today's USD red news, I may go SELL/SELL for both symbols EURUSD and USDJPY.

mpradeep Nov 13, 2015 12:03am | Post# 8

Any more progress? anyone trading with this ea? i got profit buy buy EU and UJ

MathTrader7 Nov 13, 2015 2:41am | Post# 9

Version 1.15 of the EA released. In this version a bug in auto closing the hedge basket is fixed. I updated Post 1.

budidharma19 Nov 13, 2015 2:55am | Post# 10

Dear MathTrader,

Thanks for the EA,... truly I need the clear tutorial when to apply BUY/SELL , SELL/BUY, SELL/SELL or BUY/BUY,....

May be you have better clear hints how to determine that operation.

Looking forward to have answer from you,...

Thanks,

Budi

mpradeep Nov 13, 2015 3:56am | Post# 11

Dear Mathtrader

Where is is version 1.15. need to download.

jagzuk Nov 13, 2015 4:20am | Post# 12

Dear Mathtrader Where is is version 1.15. need to download.
Download from post 1. MathTrader updated the file (see the section at the end of post1 that says Update, and date after the download link?). Best Regards.

BLACKFEET Nov 13, 2015 8:42am | Post# 13

1 Attachment(s)
Hi, Mathtrader

I used your EA with the last NEW : Core Retail Sales.

Everything worked perfect...but I asked for 30 bucks and it gave me only $10.91 (LOL)

Thanks

Best regards

BBF
Click to Enlarge

Name: 20151113_EURUSD.png
Size: 8 KB

techlover Nov 13, 2015 8:53am | Post# 14

Still Ea not closing trades at desired profit , kindly have a look Math Thank you

MathTrader7 Nov 13, 2015 9:33am | Post# 15

Still Ea not closing trades at desired profit , kindly have a look Math Thank you
Are you using the last version (v1.15)?

MathTrader7 Nov 13, 2015 9:33am | Post# 16

Hi, Mathtrader I used your EA with the last NEW : Core Retail Sales. Everything worked perfect...but I asked for 30 bucks and it gave me only $10.91 (LOL) Thanks Best regards BBF {image}
Good results!
We have to accept what market gives us

techlover Nov 13, 2015 9:36am | Post# 17

{quote} Are you using the last version (v1.15)?
I am Using v1.10 , sorry i will test latest version

As of now the results with this Ea are very good , even we can use it for Scalping
have to test it few more days

techlover Nov 13, 2015 9:43am | Post# 18

1 Attachment(s)
New Version is Perfect
Click to Enlarge

Name: jpy.png
Size: 7 KB

MathTrader7 Nov 13, 2015 9:59am | Post# 19

{quote} I am Using v1.10 , sorry i will test latest version As of now the results with this Ea are very good , even we can use it for Scalping have to test it few more days
Trading hedge is one of my favorite strategies. As you mentioned, we can use it for scalping here and there. Please post your results which may help other traders to learn this style of trading.

techlover Nov 13, 2015 10:06am | Post# 20

{quote} Trading hedge is one of my favorite strategies. As you mentioned, we can use it for scalping here and there. Please post your results which may help other traders to learn this style of trading.
Why cant it be Auto trading , we can set small profit and use for scalping

leave the trader to chose the option of Buy/sell or Sell /Sell


© Forex Factory