title: Fit algorithm does not accept my data
body: <p>I'm using the algorithm described <a href="http://www.scipy.org/Cookbook/FittingData" rel="nofollow noreferrer">here</a> to fit Gaussian bell curves to my data.</p>
  <p>If I generate my data array with:</p>
  <pre><code>x=linspace(1.,100.,100)
  data= 17*exp(-((x-10)/3)**2)
  </code></pre>
  <p>everything works fine.</p>
  <p>But if I read the data from a text file using</p>
  <pre><code>file = open(&quot;d:\\test7.txt&quot;)
  arr=[]
  data=[]
  
  
  def column(matrix,i):
      return [row[i] for row in matrix]
  
  for line in file.readlines():
      numbers=map(float, line.split())
      arr.append(numbers)
      
  data = column(arr,300)
  x=linspace(1.,115.,115)
  </code></pre>
  <p>I get the error message:</p>
  <pre><code>Traceback (most recent call last):
  File &quot;readmatrix.py&quot;, line 60, in &lt;module&gt;    fit(f, [mu, sigma, height], data)
  File &quot;readmatrix.py&quot;, line 42, in fit    if x is None: x = arange(y.shape[0])
  AttributeError: 'list' object has no attribute 'shape'
  </code></pre>
  <p>As far as I can see, the values included in data are correct, it looks like:</p>
  <pre><code>[0.108032, 0.86181600000000003, 1.386169, 3.2790530000000002, ... ]
  </code></pre>
  <p>Has someone a clue what I am doing wrong?</p>
  <p>Thanks!</p>