Achim,
I found unusual behavior, or even possibly a bug, in zoo. When I run the
code below, R crashes. There is no error message, R simply exits with no
warning.
library(zoo)
x <- runif(140000, 2009, 2010) # Random days in 2009
x <- as.yearmon(x) # This works
table(x) # This crashes. print(x) also crashes R.
summary(x) does not
However, if I change the number of random dates to 130000, there is no
problem.
I have been using zoo for a few years with no problems, including using
code similar to the one above. I did just upgrade to R 2.11.0 and this is
my first use of zoo for a large vector since the upgrade.
I cannot tell if the problem is with zoo or R or my machine. I tried
installing zoo from CRAN instead of R-Forge, but that did not help.
Increasing the memory limit to 3G did not help either.
I attached relevant (and irrelevant) system information below. I am using R
with Tinn-R and Tinn-R loads some packages (Hmisc, R2HTML, etc.)
Thank you for your help.
Lester Wollman
Corporate Statistician
Symmetricom, Inc.
lwoll...@symmetricom.com
sessionInfo()
R version 2.11.0 (2010-04-22)
i386-pc-mingw32
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United
States.1252 LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C LC_TIME=English_United
States.1252
attached base packages:
[1] grDevices datasets splines graphics stats tcltk utils
methods base
other attached packages:
[1] svSocket_0.9-48 TinnR_1.0.3 R2HTML_2.0.0 Hmisc_3.7-0
survival_2.35-8
loaded via a namespace (and not attached):
[1] cluster_1.12.3 grid_2.11.0 lattice_0.18-5 svMisc_0.9-57
System Information:
Windows XP Professional Version 2002 Service Pack 3
Computer Information:
Dell with Intel CPU
T2600 @ 2.16 GHz, 1G of RAM
zoo information
packageDescription("zoo")
Package: zoo
Version: 1.6-3
Date: 2010-02-22
Title: Z's ordered observations
Author: Achim Zeileis, Gabor Grothendieck, Felix Andrews
Maintainer: Achim Zeileis <achim.zeil...@r-project.org>
Description: An S3 class with methods for totally ordered indexed
observations. It is particularly aimed at irregular time series of numeric
vectors/matrices and factors. zoo's key design goals are independence of a
particular index/date/time class and consistency with ts and base R by
providing methods to extend standard generics.
Depends: R (>= 2.10.0), stats
Suggests: coda, chron, DAAG, fCalendar, fSeries, fts, its, lattice,
strucchange, timeDate, timeSeries, tis, tseries, xts
Imports: stats, utils, graphics, grDevices, lattice (>= 0.18-1)
LazyLoad: yes
License: GPL-2
URL: http://R-Forge.R-project.org/projects/zoo/
Repository: R-Forge
Repository/R-Forge/Project: zoo
Repository/R-Forge/Revision: 688
Date/Publication: 2010-03-20 02:29:04
Packaged: 2010-03-20 21:59:26 UTC; rforge
Built: R 2.11.0; ; 2010-03-22 14:03:33 UTC; windows
-- File: C:/PROGRA~1/STATIS~1/R2110/library/zoo/Meta/package.rds