title: How to get the first column of the list?
body: <p>I want to extract the data for the first column. I want the output only have <code>[male, farmer]</code> and the rest are ignored. What should I do?</p>
  
  <pre><code>import numpy as np
  from scipy import stats
  
  data = np.array([[11, "male",1222,"teacher"],[23,"female",333,"student"],[15,"male",542,"security"],[44,"male",4422,"farmer"],[25,"female",553,"farmer"]])
  
  # type of the data above
  types = ["num","cat","num","cat"]
  idx = []
  for index, _type in enumerate(types):
      if _type == 'cat':
          idx.append(index)
  
  mode = []
  for i in idx:
      mode.append(stats.mode(data[:,i]))
  print("mode: {}".format(mode))
  </code></pre>
  
  <p>If the code <code>[sub[0] for sub in mode]</code> is included in the code, the output is still messy although only have the first column (the output is shown below).</p>
  
  <p><code>mode: [array(['male'], dtype='&lt;U11'), array(['farmer'], dtype='&lt;U11')]</code></p>