[R-sig-finance] fBasics / timeSeries() - memory issue?
Adam Klein
Adam.Klein at aqrcapital.com
Wed Dec 29 19:14:16 CET 2004
Hi all,
I'm new to R and using R v2.0.0 and fBasics 200.10058, and trying to construct a timeSeries from a data frame (it's a currency total return index). I'm wondering if there are memory-related issues because I can only load 7567 dates into memory across 51 countries; but when I try to load 7568 periods I get an error:
> len
[1] 7567
> myTS <- timeSeries(recs[1:len,2:51], recs[1:len,1], units=names(recs)[2:51]) # THIS WORKS
> len<-len+1
> len
[1] 7568
> myTS <- timeSeries(recs[1:len,2:51], recs[1:len,1], units=names(recs)[2:51]) # THIS DOESN'T WORK
Error in if (timeTest == 0) iso.format = "%Y-%m-%d" :
missing value where TRUE/FALSE needed
Does anyone think this might be a memory issue? How could I check?
The recs data frame looks like this ...
> str(recs)
`data.frame': 8867 obs. of 51 variables:
$ TIME: chr "1970-12-31 16:00:00" "1971-01-01 16:00:00" "1971-01-04 16:00:00" "1971-01-05 16:00:00" ...
$ AR : num NA NA NA NA NA NA NA NA NA NA ...
$ AU : num NA NA NA NA NA NA NA NA NA NA ...
$ BD : num NA NA NA NA NA NA NA NA NA NA ...
$ BG : num NA NA NA NA NA NA NA NA NA NA ...
$ BR : num NA NA NA NA NA NA NA NA NA NA ...
...
Thanks!
--Adam
Disclaimer: This e-mail may contain confidential and/or privileged information. If you are not the intended recipient or have received this e-mail in error, please notify the sender immediately and destroy/delete this e-mail. You are hereby notified that any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly prohibited.
This communication is for informational purposes only. It is not intended as an offer or solicitation for the purchase or sale of any financial instrument or as an official confirmation of any transaction. All information contained in this communication is not warranted as to completeness or accuracy and is subject to change without notice. Any comments or statements made in this communication do not necessarily reflect those of AQR Capital Management, LLC and its affiliates.
More information about the R-sig-finance
mailing list