plotfit: Plot x-y data and a fitted model

Description Usage Arguments Value See Also Examples

Description

Extract the original data from a fitted model and plot these data along with a smooth curve of the fitted model function. The fitted model must be for one covariate only.

Usage

1
2
3
plotfit(fm, ...)
## S3 method for class 'nls'
plotfit(fm, ...)

Arguments

fm

A fitted model object, typically a nls fitted model.

...

Arguments to be passed to xyplot or panel.curve.

Value

A lattice object.

See Also

xyplot, panel.curve

Examples

1
2
3
fm1 <- nls(rate ~ conc/(K + conc), Puromycin, c(K = 0.05),
           subset = state == "treated", alg = "plinear")
plotfit(fm1, from = 0)

NRAIA documentation built on May 2, 2019, 4:52 p.m.

Related to plotfit in NRAIA...