title: Storing datetime in numpy array
body: <p>Let's say I want to store datetime values over 100 iterations of a for loop in a numpy array like so: </p>
  
  <pre><code>import numpy as np
  import time 
  from datetime import datetime
  
  Startmult = np.zeros((1,100))
  for i in range(100): 
      Startmult[i] = datetime.now()
  </code></pre>
  
  <p>Whenever I do this, I get the following error:</p>
  
  <pre><code>float() argument must be a string or a number, not 'datetime.datetime'
  </code></pre>
  
  <p>Is there a way to overcome this error?</p>
  
  <p>Thank you for your help!</p>
  
  <p>EDIT: Also, now I would like to do the following, but can't seem to find a solution: </p>
  
  <pre><code> CPUtime = np.zeros((100), dtype='datetime64[s]')
   for i in range(100): 
       Start = datetime.now() 
       CPUtime[i] = datetime.now()-Start
  </code></pre>
  
  <p>In now get the following error: </p>
  
  <pre><code>Could not convert object to NumPy datetime
  </code></pre>