QuadHedge cacus' way. - page 3

 

cool .. the other thing i was wondering was have you considered doing a 3 way trade? its pretty complicated, and i'm not sure of the exact details yet, but basically like this:

1. GBPUSD

2. EURUSD

3. EURGBP

Now if you know the direction that 1 and 2 are moving in, you'd know the direction that 3 moves in. I'll post a more detailed example later, but I'm wondering whether its possible to use this to your advantage.

 

Yes, i have already thought about that.

But since that would be even more risky than another quadhedge then a better approach for extra profits would be adding another EA on another chart.

Why "more risky"? this is how i understood what you may mean:

Let's see this with an example, when one of the couples gets in profit, let's suppose BUY GU SELL EU. That means clearly that EG is moving down quickly.

So, if we had entered a SELL and a BUY in EG then the SELL order would be in profit so far.

So, when we reach the PipsTrigger objective then close the couple in profit and the SELL EG order.

What happen if EG continues going down? Well, our first couple would still low and off course our BUY in EG would be the same.

If EG sudendly starts the retracement then our couple would be in profit quickly (at least compared with the already closed one), and off course our BUY would be less down than before...

If that BUY EG gets a number of negatives pips less "in absolute value" than the firstly SELL EG order closed then we would be adding some extra profit.

This is similar to add another quadhedge with another chart with the EA attached and magicnumber changed off course. But i think that the quadhedge would be more secure under all the circumstances since divergence needs to be HIGH enough to make a notiseable change in the quadhedge, but a single pip EG goes down will be killing that single BUY EG quicker.

This is how i see this, what do you think? maybe you can throw me some lines.

Oh, attached is the v2.5, added some features and corrected a LOT of annoying errors.

Regards!

Files:
 

hmmm let me think about it, and i'll get back to you!

in the meanwhile, i setup my forward test with your version 2.5 using 40/20.

MT4Live.com - Share Your MT4 Statements Free

it only opened 1 trade though, is that right ? i thought it should open 4.

could you email me the code as well, i'd like to see it ! thx. my email address is my username followed by @ gmail .com

 

I've sent you a mail

Check your inbox.

No, it is not supposed to open just one order.

Please check you dairy or experts log to see if there's something wrong and let me know ASAP.

Regards!

 

thanks, just emailed you - cant see any errors, and v2.3 did open 4 orders for me, so it must have been something that changed in between.

as for my other idea - OK, so we have 2 couples of GU and EU. 1 couple will close in profit after a while. So now we have 1 losing couple left. Lets say its a Buy GU and Sell EU.

Bit of math in the meanwhile ...

GBPUSD = USD/GBP and EURUSD = USD/EUR. EURGBP = GBP/EUR, i.e. (USD/EUR)/(USD/GBP), i.e. EURUSD / GBPUSD. This relationship holds by arbitrage, it'd be very rare to see it wrong by more than a couple of pips.

Now we know that Buy GBPUSD and Sell EURUSD is in loss (that was our losing couple). And we're expecting that loss to reduce by PipsInGain amount before we close the losing couple. When this loss is reducing in size, the Sell must start winning, and the buy must start winning too, i.e. GBPUSD is rising, and EURUSD is falling.

GBPUSD was our denominator and EURUSD was our numerator (math bit above). Denominator rising, numerator falling means whole fraction reduces, i.e. EURGBP is going to fall if our BuyGU+SellEU couple is reducing its loss. So if NOW WE OPEN a SELL EURGBP order just after our winning couple is closed, then we'd only need the price to move by (PipsInGain/2) to reach our target - i.e. the SELL EURGBP will give us some winning pips, and the losing couple will go from -100 loss to -90 loss giving us some winning pips. This means our losing couple can be closed faster (it doesnt have to go to -80, we might be able to close it at -90).

Hope that made sense .. numbers purely hypothetical of course, and will be dependent on spreads. It might be a bit more risk as if the losing couple starts losing even more, then we'd lose on the EURGBP order as well.

The good thing about this way is that because the math relationship holds by arbitrage, you're guaranteed that if the losing couple is moving in a favorable direction, then your EURGBP order is moving in a favorable direction as well, hopefully meaning that the 3 open positions can be closed faster.

 

OK not sure what happened .. i tried 2.5 again, and its working - it opened 4 orders. I'll start my forward test again from tomorrow morning.

 

All arbitrage opportunities are easily negated by the spread from the brokers. Not trying to say this EA won't work, but you should first realize you are not in fact using "arbitrage."

I still do not see the reason for the hedge either, if you could properly track both positions, you should just enter the short side when the correlation deviation is expected to shrink.

In general Hedged position will ultimately just add to the brokers coffer, and take from yours, then again this is just my opinion. Feel free to show me evidence that supports it otherwise.

 
Styex:
All arbitrage opportunities are easily negated by the spread from the brokers. Not trying to say this EA won't work, but you should first realize you are not in fact using "arbitrage."

Yep I realize that completely. I'm not exploiting any arbitrage opportunity at all in my suggestion above. I'm only exploiting the fact that I know which direction the EURGBP pair will move in IF I know which direction the GBPUSD and EURUSD pairs are moving. In fact, my suggestion relies on the market being efficient, i.e. no arbitrage opportunities ! And from my observations, this assumption is good - there is rarely a > 2-3pip difference between expected and actual value. If there was an sizeable arbitrage opportunity available, it would be bad for my suggestion above because then it wouldnt work.

 

Dear Cacus,

I have also been writing an EA for trading correlation, so it is interesting to find this post and meet others on the same quest.

I think there is a good job being done in this thread.

However I must agree with Styex who said "I still do not see the reason for the hedge either, if you could properly track both positions, you should just enter the short side when the correlation deviation is expected to shrink."

Clearly if you are measuring the correlation in real time then there is no point opening 4 trades (you are wasting money on excess spreads)...just open one pairs of trades when you expect the correlation to shrink and try to get your 10-20 pips then. What point is there in building up a winning pair of trades and a losing pair of trades...they simply cancel out and waste spreads.

By the way over the last couple of days my EA has been logging the extremes of GBPUSD versus EURUSD correlation. It seems that they can fall about 200 pips out of correlation and although this is partly recouped the next day or two, they seem to be left in a permanent new zone of correlation. For example if you open one pair of trades (buy EURUSD, sell GBPUSD) with a TP of 20 pips equity profit, or 200 pips equity stoploss...then you might find that the correlation lapses after news or whatever and that it pushes the equity say 180 pip negative. Although it might settle back to to -150 pips you are unlikely to ever get to the TP of +20 anytime soon after such a big move against you. The big move almost seems to become partly permanent. However if you can measure the correlation somehow in real time so that you realise that a new extreme has been reached and is expected to pullback slightly, then you can open the trades then in the hope of capturing some of the pullback. My EA is not yet capable of doing that...it simply opens a pair of trades in the hope that they are correlated at that time. Adding the capability to only enter the trades at an optimum moment is the next stage in progress. Finally, whatever solution us folks come up with...it is essential to includes a stoploss at all times, without that it is useless in the long run. Lets hope this quest proves a success.

Cacus, please post the indicator that you show on your chart to measure volatilty.

Best regards,

Pipalot

 
pipalot1:

Cacus, please post the indicator that you show on your chart to measure volatilty.

Sorry I meant to ask you to post the correlation histogram (indicator) that is shown on your chart, (not volatility).

Pipalot

Reason: