Help for writing an EA

 
Are there any ways to write an EA code that recognize crossover of two indicators in a single chart?  For example I put RSI and MA in a chart and want to know when they cross each other's. 
 
Look at this search results links.
 
arezaei:
Are there any ways to write an EA code that recognize crossover of two indicators in a single chart?  For example I put RSI and MA in a chart and want to know when they cross each other's. 

RSA and MAs are different scales so any cross will not be useful.

 
Keith Watford:

RSA and MAs are different scales so any cross will not be useful.

We can see their cross in the chart I mean how detect it in an EA. 
 
Sergey Golubev:
Look at this search results links.
Unfortunately I could not find the solution. 
 
arezaei :
Are there any ways to write an EA code that recognize crossover of two indicators in a single chart?  For example I put RSI and MA in a chart and want to know when they cross each other's. 

RSI and MA will never cross - in principle they cannot cross.

 
Vladimir Karputov:

RSI and MA will never cross - in principle they cannot cross.

I mean when they put in a single chart. 
 
arezaei :
I mean when they put in a single chart. 

How do you imagine that? It's impossible.

 
arezaei:

This is a visual deception. It is checked as follows: change the scale of the chart, change the size of the window.

 
Vladimir Karputov:

This is a visual deception. It is checked as follows: change the scale of the chart, change the size of the window.

Only way I could think of how to do it is to use a normalization function. TANH as an example. This way all values are "squeezed" into the range of 0.0 to 1.0 and therefore can be compared. 

Although it needs to be said, the scale of TANH is not linear and it might be smart to use an offset before normalizing the value. 

As a suggestion, maybe it is possible to use the lowest low value of the last x periods as your offset, then subtract this value from all values you want to compare and push it through a TANH function. Voila, you can now compare.

But dont ask for the results of this operation. - I dont know if you will get, what you want.

Reason: