title: pandas save date in ISO format?
body: <p>I'm trying to generate a Pandas DataFrame where date_range is an index. Then save it to a CSV file so that the dates are written in ISO-8601 format.</p>
  
  <pre><code>import pandas as pd
  import numpy as np
  from pandas import DataFrame, Series
  
  NumberOfSamples = 10
  dates = pd.date_range('20130101',periods=NumberOfSamples,freq='90S')
  df3 = DataFrame(index=dates)
  df3.to_csv('dates.txt', header=False)
  </code></pre>
  
  <p>The current output to dates.txt is:</p>
  
  <pre><code>2013-01-01 00:00:00
  2013-01-01 00:01:30
  2013-01-01 00:03:00
  2013-01-01 00:04:30
  ...................
  </code></pre>
  
  <p>I'm trying to get it to look like:</p>
  
  <pre><code>2013-01-01T00:00:00Z
  2013-01-01T00:01:30Z
  2013-01-01T00:03:00Z
  2013-01-01T00:04:30Z
  ....................
  </code></pre>