I have a very old version of S-PLUS 2000 Professional Release 3 and I am
running into an error in making predictions using a Generalized Additive
Model. All works well until I ask for predictions and then I receive
the warning message
Length of longer object is not a multiple of the
length of the shorter object in: x * w.factor
I believe that this is a known bug but I cannot find a fix that works
for me. I found two possible solutions posted in the s-news archive:
1. ... groom your original data before creating the gam object:
>original.data <- na.omit(original.data)
(from thread Subject: [S] summary: predict.gam() with newdata= ; From:
John Thaden <jjthaden@life.uams.edu>; Date: Tue, 08 Sep 1998 01:52:46
-0500)
and
2. ... I had a masked version of model.matrix.default in one of my
directories. Removing it fixed the behavior of predict.
(from thread Subject: Re: [S] Behavior of predict in Splus 2000; From:
Anne York <york@orca.akctr.noaa.gov>; Date: Tue, 5 Oct 1999 07:10:07
-0700 (PDT))
Solution 1 did not work and I don't understand how to execute solution
2. Could someone either explain how to remove a masked version of
model.matrix.default or offer another solution. Also, I suspect that
upgrading would solve the problem, but could someone confirm this fact.
Thank you in advance,
Charles Griffiths
********************************************************************
Charles Griffiths
National Center for Environmental Economics
Room 4316f, EPA West, Mail Code 1809T
U.S. Environmental Protection Agency
1200 Pennsylvania Avenue, N.W.
Washington, D.C. 20460
Phone: 202/566-2288 Fax: 202/566-2338
Email: griffiths.charles@epamail.epa.gov
********************************************************************
|