Skip to content
Back to formatted view

Raw Message

Message-ID: <4343C637.6040908@lancaster.ac.uk>
Date: 2005-10-05T12:25:27Z
From: Barry Rowlingson
Subject: R crashes for large formulas in lm() (PR#8180)
In-Reply-To: <20051005121210.9ECE41DD2B@slim.kubism.ku.dk>

> set.seed(123)
> x1 <- runif(1000)
> x2 <- runif(1000)
> x3 <- runif(1000)
> x4 <- runif(1000)
> x5 <- runif(1000)
> x6 <- runif(1000)
> x7 <- runif(1000)
> x8 <- runif(1000)
> y <- rnorm(1000)
> fit <- lm(y~(x1*x2*x3*x4*x5*x6*x7*x8)^2)

  For me (with 9 variables) this crashes in model.matrix:

  > f1=y~(x1*x2*x3*x4*x5*x6*x7*x8*x9)^2
  > model.matrix(f1)
  Segmentation fault

  I guess someone with a debug-compiled R can get a bit further...

Baz