title: Noob Python Coder Here! Looping Column Headers Into Stats.Linregress Function
body: <p>Trying to loop column headers into a function to compare r-squared values between any given column and the final column of a dataframe. Coding in Jupyter notebook.</p>
  
  <p>Example:</p>
  
  <pre><code>r_value = stats.linregress(filename.[first_column], filename.[last_column])
  </code></pre>
  
  <p>Need to loop this logic starting with column 1 and ending with column n-1 and then print column header and the corresponding r_value(s).</p>
  
  <p>Any help would be much appreciated!</p>