title: How to save a mix of strings and numbers into text files in specified format using numpy.savetxt?
body: <p>with one array of strings and the other array of numbers, like</p>
  
  <pre><code>str_arr = np.array(['object1_short', 'object2_intermidiate', 'object3_long'])
  </code></pre>
  
  <p>and</p>
  
  <pre><code>flt_arr = np.array([10.01234235, 11.01234235, 12.023432])
  </code></pre>
  
  <p>How can I specified <code>fmt</code> in <code>np.savetxt</code> so that the text file will be </p>
  
  <pre><code>object1    10.01
  object2    11.01
  object3    12.02
  </code></pre>
  
  <p>, i.e., two arrays in <code>%7s</code> and <code>%4.2f</code> respectively.</p>
  
  <p>I really want to use <code>numpy.savetxt</code> to do this, but directly specifying </p>
  
  <pre><code>np.savetxt("output.txt", np.vstack([str_arr, flt_arr]).T), fmt = '%7s %4.2f')
  </code></pre>
  
  <p>seems doesnot work. Is it doable with <code>savetxt</code> at all? I really prefer a <code>numpy.array</code> based solution rather than going for spliting and reformating using list comprehensions, or recarrays.</p>
  
  <p>Thanks. </p>