[R] Error: (subscript) logical subscript too long

Peter Ehlers ehlers at ucalgary.ca
Mon Apr 2 19:14:44 CEST 2012


On 2012-04-02 08:52, IOANNA wrote:
> Hello,
>
> I am trying to perform a logistic regression using counts. For example:
>
> cedegren<-
> read.table("http://www.cloudstat.org/index.php?do=/attachment/download/id_95
> /", header=T)
> attach(cedegren)
> ced.del<- cbind(sDel, sNoDel)
> ced.logr<- glm(ced.del ~ cat + follows + factor(class),
> family=binomial("logit"))
>
> This works. However, if I change the family to Gaussian:
>
> ced.logr<- glm(ced.del ~ cat + follows + factor(class), family=gaussian)
>
> I get the error:
> Error: (subscript) logical subscript too long
>
> I would like to use the probit function. Is this possible?

I think that you don't understand the 'family=' argument in glm (nor,
perhaps, generalized linear models as such).

Hint: check ?family.

Peter Ehlers

>
> Best regards,
> Ioanna
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list