title: problems with numpy.savetxt
body: <p>I am using python 2.6, and I am trying to write vector on a file with savetxt from numpy.</p>
  
  <p>In a older program I wrote at the university, I needed to read data from a file, transform the last column from degree to radiants, and write the result on another file; this is what I came up with:</p>
  
  <pre><code>import math
  import numpy as np
  
  vec=[]  
  with open("In.txt") as f:
      for line in f:
          a = float(line.split()[0])
          b = float(line.split()[1])
          c = float(line.split()[2])
          rad = math.pi/2.-(float(line.split()[3])*math.pi/180.)
          vec.append((a,b,c,rad))
  np.savetxt("Out.txt",vec)
  </code></pre>
  
  <p>Everything went as expected: in the Out.txt I had my data dislayed correctly as a table.</p>
  
  <p>Now I am trying to do something similar: I read data from a file, perform some operation, and writing the result in a file:</p>
  
  <pre><code>fout=open("Out.txt",'a')
  
  for n in range(nsteps)
    with open("In.txt") as fin:
      for line in fin:
        #long operations: at the end I have a vector par with 4 elements
        #I want to write this vector as a new line in my output file
        np.savetxt(fout,par)
  fout.close()
  </code></pre>
  
  <p>The problem is that in the output I have only one column:</p>
  
  <pre><code>par[0]
  par[1]
  par[2]
  par[3]
  par[0]
  par[1]
  ...
  </code></pre>
  
  <p>if I write <code>par</code> on the terminal at every step I have it correctly displayed as:</p>
  
  <pre><code>[par[0],par[1],par[2],par[3]]
  ...
  </code></pre>
  
  <p>what am I doing wrong?</p>