title: Timing a single block in Jupyter with one line of code
body: <p>How do you time a single block of a Jupyter notebook with a single line of. Python code? </p>
  
  <p>%time and %timeit don't cut it, but there must be a way to do this! </p>
  
  <pre><code>%time
  %timeit
  start = time.time()
  
  ## Create a Pandas dataframe from reader
  df = pd.DataFrame(reader.readrows())
  end = time.time()
  print('Time taken ', end-start,' seconds')
  </code></pre>
  
  <p>Thanks, Nic</p>