[R] help with R

Prof Brian Ripley ripley at stats.ox.ac.uk
Thu Dec 1 08:27:43 CET 2005


On Wed, 30 Nov 2005, Ed Wang wrote:

> Berton,
>
> Firstly, thanks for your comments.
>
> To address the what you first said, plotting the 3690-element vector is what
> is causing R to hang.

Well, amongst the things you are not telling us are your OS and version of 
R and what commands you are using.

The only relevant thing I know of is that NT-based versions of Windows 
were causing R to take a long time (but not hang completely) when plotting 
longish series in 2.1.0, but that was worked around in 2.1.1, and even 
there n=3690 would only just begin to show up the Windows bug.

>  Rather than lose everything I've entered by hand each
> interactive run I've switched to using a batch script, which I can now load
> and run at prompt.  Using sink("filename.txt") I'm able to save the output
> to study.
>
> My usage of dummy variables is to identify seasonality on the daily level
> over
> 15 years with 246 days per year.  I need to identify the day each month
> when an (expected) event is occuring.  The date the event occurs does
> not occur on necessarily the same day each month.  I don't know of
> another method that could identify these statistically significant seasonal
> events using R.  Dummy variables with a LM is the only method I have
> experience with using R.  If you or anyone has suggestions on what other
> methods to use I would appreciate some suggestions.  Using 245 dummy
> variables is quite awkward.
>
> I see lag() can be used to build a first- or multi-order differenced time
> series to extract any underlying trend in a time series.
>
> Using STL() might be promising.  It appears to be similar to other methods
> I've used with MINITAB but called something different.
>
> Nor an ARIMA nor a BSM is really what I need as I'm not focused on
> performing predictions or modeling of the (possibly non-normal) properties
> of the residuals.
>
> Thanks.  All your advice is greatly appreciated.
>
> Ed
>
>       "A man is not old until regrets take the place of dreams."
>                     Actor John Barrymore
>
>
>
>
>
>
> From: Berton Gunter <gunter.berton at gene.com>
> To: "'Ed Wang'" <eymw at hotmail.com>, <r-help at stat.math.ethz.ch>
> Subject: RE: [R] help with R
> Date: Tue, 29 Nov 2005 11:05:02 -0800
>
> You're not telling us something or there's a problem with your R build: a
> 3960 element vectors of integer is tiny and will not cause R to crash.
>
> Regarding your regression model. You do **not** need dummy variables in R.
> Please read the docs (e.g. AN INTRODUCTION TO R) and help files on lm() and
> factor() to see how to do linear modeling in R. lag() and diff() may also be
> relevant. OTOH, R has many better ways to model time series and seasonality,
> both in base R and numerous add-on packages. Try help.search('time series')
> and RSiteSearch('time series')
>
> -- Bert Gunter
> Genentech Non-Clinical Statistics
> South San Francisco, CA
>
> "The business of the statistician is to catalyze the scientific learning
> process."  - George E. P. Box
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
>

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595




More information about the R-help mailing list