ml <- lm(Sepal.Length ~ Sepal.Width, iris)
tt <- tablefreq(iris[,c("Sepal.Length","Sepal.Width")])
mt <- biglmfreq(Sepal.Length ~ Sepal.Width, tt)
all.equal(coef(mt), coef(ml))
coef(mt)
chunk1 <- tt[1:30,]
mf1 <- biglmfreq(Sepal.Length ~ Sepal.Width, chunk1)
chunk2 <- tt[-c(1:30),]
mf2 <- update(mf1, chunk2)
all.equal(coef(mf2), coef(ml))
predict(mf2, iris)
Run the code above in your browser using DataLab