title: Losing "seconds" info when reading data via pandas' read_csv()
body: <p>I am trying to read a simple data with pretty much just 2 columns: id, timestamp</p>
  
  <p>since my timestamp has seconds, I want to preserve that info. So I read into many articles such as:</p>
  
  <p><a href="https://stackoverflow.com/questions/40214647/error-when-parsing-timestamp-with-pandas-read-csv">Error when parsing timestamp with pandas read_csv</a></p>
  
  <p><a href="https://stackoverflow.com/questions/34122395/reading-a-csv-with-a-timestamp-column-with-pandas">Reading a csv with a timestamp column, with pandas</a></p>
  
  <p><a href="https://stackoverflow.com/questions/34122395/reading-a-csv-with-a-timestamp-column-with-pandas/34122596">Reading a csv with a timestamp column, with pandas</a></p>
  
  <p>and more.... </p>
  
  <p>Here's what I have after reading everything on here:
  I first created a short function to help me parse the timestamp data, and then used it while calling read_csv() function.</p>
  
  <pre><code>def dateparse (timestamp):
      return pd.datetime.strptime(timestamp, '%Y-%m-%d %H:%M:%S')
  
  data = pd.read_csv(os.path.join(base_dir, data_file), 
                     parse_dates=True, date_parser=dateparse)
  </code></pre>
  
  <p>but when i print the data, I still do not see seconds! :(</p>
  
  <pre><code>print(data.head(3))
  id   timestamp_utc           
   0   9/1/17 1:24 
   1   9/1/17 1:24 
   2   9/1/17 1:24
  </code></pre>
  
  <p>Any help is appreciated! </p>
  
  <p><strong><em>EDIT!!!</em></strong>
  With Jon's suggestion, I changed my code to:</p>
  
  <pre><code>data = pd.read_csv(os.path.join(base_dir, data_file), parse_dates=['timestamp_utc'], date_parser=dateparse)
  </code></pre>
  
  <p>and I would get an error:</p>
  
  <pre><code>ValueError: time data '9/1/17 1:24' does not match format '%m/%d/%y %H:%M:%S'
  </code></pre>
  
  <p>but if I do not use the parsing function:</p>
  
  <pre><code>data = pd.read_csv(os.path.join(base_dir, data_file), parse_dates=['timestamp_utc'])
  </code></pre>
  
  <p>all my timestamp would have 0 seconds:</p>
  
  <pre><code>print(data.head(3))
  id   timestamp_utc           
   0   9/1/17 1:24:00
   1   9/1/17 1:24:00 
   2   9/1/17 1:24:00
  </code></pre>
  
  <p><strong>EDIT 2:</strong>
  Here's how the data looks like originally in my csv:</p>
  
  <pre><code>0   24:31.8
  1   24:31.9
  2   24:32.3
  3   24:32.5
  </code></pre>
  
  <p>This is how it looks like <em>after</em> I change the timestamp data format (not recommended....): (showing more columns here to show that the seconds are different)</p>
  
  <pre><code>0   9/1/17 1:24:32
  1   9/1/17 1:24:32
  2   9/1/17 1:24:32
  3   9/1/17 1:24:32
  4   9/1/17 1:24:33
  5   9/1/17 1:24:33
  6   9/1/17 1:24:35
  7   9/1/17 1:24:35
  8   9/1/17 1:24:36
  9   9/1/17 1:24:37
  10  9/1/17 1:24:38
  11  9/1/17 1:24:40
  </code></pre>