Hi,
I am reading intra day data into R using:
EWW <- read.table("EWW.txt", sep=",", header =TRUE)
EWW text file:
"Date","Time","Open","High","Low","Close","Volume"
07/01/1998,10:07:00,12.63,12.63,12.63,12.63,500
07/01/1998,10:27:00,12.75,12.75,12.75,12.75,100
07/01/1998,10:29:00,12.75,12.75,12.75,12.75,100
07/01/1998,11:07:00,12.75,12.75,12.75,12.75,100
07/01/1998,13:49:00,12.75,12.75,12.75,12.75,1000
07/01/1998,14:15:00,12.94,12.94,12.94,12.94,600
I think I am having trouble converting the data to xts type, due to the date
and time fields being contained in seperate variables.
EWW.xts <- as.xts(EWW)
Error in as.POSIXlt.character(x, tz, ...) :
character string is not in a standard unambiguous format
Has anyone come across a similar problem before?
Thanks,
Eduard
07/01/1998,14:15:00,12.94,12.94,12.94,12.94,600
I think I am having trouble converting the data to xts type, due to the date
and time fields being contained in seperate variables.
EWW.xts <- as.xts(EWW)
Error in as.POSIXlt.character(x, tz, ...) :
?character string is not in a standard unambiguous format
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
07/01/1998 is ambiguous, and not ISO 8601.
http://en.wikipedia.org/wiki/ISO_8601
CCYY-MM-DD would be correct, and CCYY-MM-DD HH:MM:SS is preferred.
try something like:
_______________________________________________
R-SIG-Finance at stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-sig-finance
-- Subscriber-posting only.
-- If you want to post, subscribe first.
Jeffrey Ryan
jeffrey.ryan at insightalgo.com
ia: insight algorithmics
www.insightalgo.com
I think I am having trouble converting the data to xts type, due to the date and time fields being contained in seperate variables.
This question has been asked and answered multiple times on this list.
Please *search the archives* before posting.
See: http://catb.org/esr/faqs/smart-questions.html
Regards,
- Brian