## Fix Python – How to iterate over columns of pandas dataframe to run regression

I’m sure this is simple, but as a complete newbie to python, I’m having trouble figuring out how to iterate over variables in a pandas dataframe and run a regression with each.

Here’s what I’m doing:

all_data = {}

for ticker in [‘FIUIX’, ‘FSAIX’, ‘FSAVX’, ‘FSTMX’]:

all_data[ticker] = web.get_data_yahoo(ticker, ‘1/1/2010’, ‘1/1/2015’)

prices =….