Message-ID: <201012061334.31790.s.wood@bath.ac.uk>
Date: 2010-12-06T13:34:31Z
From: Simon Wood
Subject: Help with GAM (mgcv)
In-Reply-To: <1291636907022-3074349.post@n4.nabble.com>
OK, try...
model3=gam(Symptoms~as.factor(txerad)+as.factor(maritalStatus),family=binomial,data=data2)
or
model3=gam(data2$Symptoms~as.factor(data2$txerad)+as.factor(data2$maritalSt
atus),family=binomial)
... both types of construction work with the current mgcv:gam (and with glm).
Your construction doesn't work with the current mgcv:gam (or the current
glm).
On Monday 06 December 2010 12:01, Stressed1985 wrote:
> Ok, i just tried this:
>
> library(mgcv)
> model3=gam(data2$Symptoms~as.factor(data2$txerad)+as.factor(data2$maritalSt
>atus),family=binomial,data=data2)
>
> And im still getting this error!
>
> Error in dl[[i]] : subscript out of bounds
--
> Simon Wood, Mathematical Sciences, University of Bath, Bath, BA2 7AY UK
> +44 1225 386603 www.maths.bath.ac.uk/~sw283