title: how to convert character time to numeric value in R
body: <p>I have following column in r data frame in character format</p>
  
  <pre><code> time
   12:45:34
   01:23:00
   21:32:00
   56:32:00
  </code></pre>
  
  <p>I want it in following format</p>
  
  <pre><code> time
   12.45
   1.23
   21.32
   56.32
  </code></pre>
  
  <p>I did following</p>
  
  <pre><code> gsub("*\\:[0-9]", ".", df$time)
  </code></pre>
  
  <p>But,does not give what is intended. </p>