A formal definition of a master-slave - is there one?

 
When we look at correlated pairs (e.g. EURUSD and GBPUSD) that have been moving in sync for some time, a moment of misalignment is bound to occur. If the Poundback suddenly turns down, which is synchronously flying with the Euro, this could be a signal to sell the Euro. When one observes this process in real time, there is usually no question which pair is setting the tone. But how to formalize it? Is there a method or an Expert Advisor that performs the detection of the anchor automatically?
 

This is what I invented. I don't like such a cranky method. Perhaps you can point me to something more conventional.

Let the observation window be 10 bars.

Let's calculate the correlation coefficient between two pairs for last 10 bars and for last 11 bars. If the latter is less, it means that the mismatch starts. Let's build the charts for 10 bars. Which of the pairs on the last bar has more deviations from its mask is the main one, it breaks the current movement.

 
Simple logic: flip both pairs and count on the same segment - you get the result exactly the opposite. And all because it is impossible to determine what is a deviation from the agreed behaviour, the couple's desire to move more or, on the contrary, their reluctance to move)
 
wmlab:
When we look at correlated pairs (for instance, EURUSD and GBPUSD) that have been moving synchronously for some time, a moment of misalignment is bound to occur. If the Poundback suddenly turns down, which is synchronously flying with the Euro, this could be a signal to sell the Euro. When one observes this process in real time, there is usually no question which pair is setting the tone. But how to formalize it? Is there a method or an Expert Advisor that performs the detection of the anchor automatically?


It's not the pair that deflects or doesn't deflect the slave, but the one that reduces the deflection. And by the way, both pairs can be equally slave and master.

For example, if EURUSD and GBPUSD deviation both pairs move to the former spread between them, this is the case and then it is easier to trade EURGBP mean-reversion. If in the deviation the pound moves against the divergence, and the euras goes where it wants)), then the euro is the master, while the pound is the slave. It is also possible when both instruments are independent.

 


Pairs are now around 65% of today's range,

but pound above 65% yesterday, euro below 50% yesterday

Pound around 100% of 5 day (and 10 and 20) and Euro above 50% (5)

So the pound can be alive with its life, it goes, the euro stands, what correlation is there

I bet on the pound today (theoretically) a renewal of today's high, yesterday's

Euro updating high today, after 65% of yesterday's range we may look to buy

 
poruchik:

So the pound has a life of its own, it goes - the euro stands, what kind of correlation is there


It all depends on the scale. EURUSD M5, the blue bars are the poundbucks:


 
If the pairs go together, it means only one thing - the dollar changes in value. If they go separately, it means that either the euro or the pound is changing in value. Where do the masters and the slaves come from?
 
excelf:
If pairs go together it means only one thing - the dollar changes in value.
Oops - mistake. Either the dollar is changing in value or the euro and pound are changing together, which is more than likely.
 
wmlab:
When we look at correlated pairs (e.g. EURUSD and GBPUSD) that have been moving in sync for some time, a moment of misalignment is bound to occur. If the Poundback suddenly turns down, which is synchronously flying with the Euro, this could be a signal to sell the Euro. When one observes this process in real time, there is usually no question which pair is setting the tone. But how to formalize it? Is there a method or an Expert Advisor that performs the detection of the master automatically?

There is a method. Everything is learned by comparison. It involves calculating correlation coefficients for two cases:

  1. The first pair is taken unbiased, and the second pair is taken shifted relative to the first pair by 1 bar deep into history
  2. The first pair is taken shifted relative to the second one by 1 bar deep into the history and the second pair is taken unbiased

Let's compare the correlation coefficients obtained in points 1 and 2 in absolute values:

  • If the absolute value of the correlation coefficient for item. 1 is greater than for para. 2, then the second pair was the master and the first was the slave.
  • If the absolute value of the correlation coefficient for item. 2 is greater than for item. 1, then the first pair was the master and the second was the slave.
 
Reshetov:

There is a method. Everything is learned by comparison. It involves calculating correlation coefficients for two cases:

  1. The first pair is taken unbiased, the second pair is biased relative to the first pair by 1 bar deep into history
  2. The first pair is taken shifted relative to the second one by 1 bar deep into the history, the second pair is taken unbiased

Compare the correlation coefficients obtained in step 1 and step 2:

  • If the correlation coefficient for p. 1 is greater than for p. then the second pair was the master and the first was the slave.
  • If the correlation coefficient for item. 2 is greater than the correlation coefficient for item 1 then the first pair was the master and the first was the slave. 1, then the first pair was the master and the second was the slave.


Only if the reaction time of the slave pair to the movement of the master is greater than 1 bar. If less, you get noise.
 
alsu:
This is only if the response time of the slave pair to the movement of the master is greater than 1 bar. If less, we get noise.

Correlation coefficients for 1 bar are not calculated, but are calculated for N bars. Therefore the response of the slave pair to the movement of the master pair is obtained for a history section of N bars, not 1 bar.

There will be noise in any case. The smaller the difference in the correlation coefficients for step 1 and 2, the higher the noise. 1 and 2, the higher the noise value.

Reason: