daily pastebin goal
67%
SHARE
TWEET

Untitled

a guest Jun 18th, 2018 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Time    Concentration
  2. 12:31   128000
  3. 12:33   120500
  4. 12:34   105000
  5. 12:35   100000
  6. 12:37   115000
  7. 12:38   120000
  8.  
  9.  
  10.  
  11. setwd('C:\Users\.....’)
  12. cp = read.csv(‘……...csv',header = T)
  13. head(cp)
  14.  
  15. cp$Time = as.POSIXct(cp$Time, format = "%H:%M:%S", tz = “America/New_York”)
  16.  
  17. cp.zoo = zoo(cp[,-1], as.POSIXlt(cp[,1], format = "%H:%M:%S"))
  18. frame.zoo = zoo(NA,seq(start(cp.zoo), end(cp.zoo), by = "min"))
  19. df = data.frame(Time = as.POSIXlt(index(frame.zoo), format = "%H:%M:%S"))
  20. merging = merge(df, cp, all = TRUE)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top