I am developing a high frequency trading system and am having trouble overcoming one obstacle: importing quotes (every 10 seconds) and having them stored so I could calculate correlation between two stocks (essentially the S&P 500 index and a stock or ETF).
I know how to import data from the web and am familiar with the CORREL function. I plan to record the prices of SPY and USO every 10 seconds (I know that you are only able to refresh data every 1-minute in Excel, but I have a VBA code that refreshes it every 10 seconds), and then use the CORREL function to see if oil is trading with the S&P futures. (I know this can be easily seen on a chart, but I will have many other variables and desire to quantify the whole process).
Doe's anyone know how I can save the data in a cell every 10 seconds so that I can calculate the correlation. Is this only possible using VBA?
Any thoughts on different ways of approaching this would be greatly appreciated.
I know how to import data from the web and am familiar with the CORREL function. I plan to record the prices of SPY and USO every 10 seconds (I know that you are only able to refresh data every 1-minute in Excel, but I have a VBA code that refreshes it every 10 seconds), and then use the CORREL function to see if oil is trading with the S&P futures. (I know this can be easily seen on a chart, but I will have many other variables and desire to quantify the whole process).
Doe's anyone know how I can save the data in a cell every 10 seconds so that I can calculate the correlation. Is this only possible using VBA?
Any thoughts on different ways of approaching this would be greatly appreciated.
