title: How to convert numeric time into date, time format in R
body: <p>Trying to build an xts for my data. The date fromat it okay but I dont know how to convert "time" column into a time format. Time is stored as numeric, the data looks like:</p>
  
  <pre><code>      date time  price
  1 19900102  930 353.40
  2 19900102  931 353.25
  3 19900102  932 353.02
  4 19900102  933 352.97
  5 19900102  934 352.81
  6 19900102  935 352.74
  
  </code></pre>
  
  <p>I tried the following code but it doesnt work.</p>
  
  <pre><code>sp500.xts &lt;-  as.xts(sp500[,3],order.by=as.POSIXct(strptime(paste(as.character(sp500[,1]),as.character(sp500[,2])),"%Y%m%d %H:%M")))
  </code></pre>
  
  <p>Thanks for anyone who helps.</p>