Examples for 's20x::modcheck'


Model checking plots

Aliases: modcheck modcheck.lm

Keywords: hplot

### ** Examples


# An exponential growth curve
e = rnorm(100, 0, 0.1)
x = rnorm(100)
y = exp(5 + 3 * x + e)
fit = lm(y ~ x, data = data.frame(x, y))
modcheck(fit)
plot of chunk example-s20x-modcheck-1
# An exponential growth curve with the correct transformation
fit = lm(log(y) ~ x, data = data.frame(x, y))
modcheck(fit)
plot of chunk example-s20x-modcheck-1
# Peruvian Indians data
data(peru.df)
modcheck(lm(BP ~ weight, data = peru.df))
plot of chunk example-s20x-modcheck-1

[Package s20x version 3.1-31 Index]