How do I use for loops to test all stocks against each other and output answer into a matrix?
1 view (last 30 days)
Show older comments
I need to perform a correlation test on a universe of stocks in a given list. I have the yahoo fetch command utilised so that when I get the names of both stocks it downloads them, joins them and does the test. This all works well.
The problem I am encountering is that I can only get the for loop(s) to do one of the iterations needed.
I need to use the same list but the first loop should look at the first item on the list and the second loop should then move through every item on that list and the first loop should not move to the second until all of the first stock has been tested against each of the other and so on....
0 Comments
Answers (0)
See Also
Categories
Find more on Logical in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!