Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- qn: what's wrong with the following csv, dates are not properly read!
- plz help!
- d4.csv
- ======
- "Date","Open","High","Low","Close","Volume","Adj"
- 17-03-2008 00:05:00,65.45,65.5,65.05,65.05,0,0
- 18-03-2008 00:06:00,65.45,65.5,65.05,65.05,0,0
- 19-03-2008 00:07:00,65.45,65.5,65.05,65.05,0,0
- R-console
- =========
- > getSymbols('d4');head(D4)
- [1] "D4"
- D4.Open D4.High D4.Low D4.Close D4.Volume D4.Adjusted
- 2011-09-10 65.45 65.5 65.05 65.05 0 0
- 2011-09-10 65.45 65.5 65.05 65.05 0 0
- 2011-09-10 65.45 65.5 65.05 65.05 0 0
- > str(D4)
- An ‘xts’ object from 2011-09-10 to 2011-09-10 containing:
- Data: num [1:3, 1:6] 65.5 65.5 65.5 65.5 65.5 ...
- - attr(*, "dimnames")=List of 2
- ..$ : NULL
- ..$ : chr [1:6] "D4.Open" "D4.High" "D4.Low" "D4.Close" ...
- Indexed by objects of class: [Date] TZ:
- xts Attributes:
- List of 2
- $ src : chr "csv"
- $ updated: POSIXct[1:1], format: "2011-09-10 20:56:50"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement