Indicator/script to combine multiple pairs values

 

Hello everyone.

This is my first post which i decided to make because i need something, but also because i intend to give something if you help me - an interesting and useful indicator (in my opinion).

I want a script which i cannot find anywhere on the internet, and not even something to get me going. This script would have to take values from different pairs (O-H-L-C-Vol) and combine them to give other values which will be put on an offline chart.

For example, if I want to calculate EURUSD divided by EURGBP (which is of course GBPUSD), the script would have to open the .hst files for the respective pairs and perform the calculus based on given formula (EURUSD/EURGBP) and then put the result in a new .hst file which will contain OHLC, exactly like a normal pair. It would do this for the last 100 candles, for example.

The script should be able to do other formulas, for example: (EURUSD+EURGBP)/2.

So what I dont know is how i can open the .hst files, take the last 100 values and then put them in the new hst file. i have some basic understanding of programming, so i need just an idea on how to work exactly with those .hst files.

Please if somebody could guide me here, i would be very grateful. And I promise to post my indicator here, and only here, to be used by everyone, because it may be very useful for many purposes, like arbitrage, correlations, averaging over multiple pairs...

Again, please give me an idea, cause i cant find anything on the internet, cause the period_converter script did not help me and because Excel is driving me insane

Thanks in advance!