# Residualfit returns the number of residual degrees of

This preview shows page 1. Sign up to view the full content.

This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ize (normally minimize) nlm(f,p) minimize function f using a Newton-type algorithm with starting values p lm(formula) ﬁt linear models; formula is typically of the form response termA + termB + ...; use I(x*y) + I(xˆ2) for terms made of nonlinear components glm(formula,family=) ﬁt generalized linear models, speciﬁed by giving a symbolic description of the linear predictor and a description of the error distribution; family is a description of the error distribution and link function to be used in the model; see ?family nls(formula) nonlinear least-squares estimates of the nonlinear model parameters approx(x,y=) linearly interpolate given data points; x can be an xy plotting structure spline(x,y=) cubic spline interpolation loess(formula) ﬁt a polynomial surface using local ﬁtting Many of the formula-based modeling functions have several common arguments: data= the data frame for the formula variables, subset= a subset of variables used in the ﬁt, na.action= action for missing values: &quot;na.fail&quot;, &quot;na.omit&quot;, or a function. The following generics often apply to model ﬁtting functions: predict(fit,...) predictions from fit based on input data df.residual(fit) returns the number of residual degrees of freedom coef(fit) returns the estimated coefﬁcients (sometimes with their standard-errors) residuals(fit) returns the residuals deviance(fit) returns the deviance fitted(fit) returns the ﬁtted values logLik(fit) computes the logarithm of the likelihood and the number of parameters AIC(fit) computes the Akaike information criterion or AIC Statistics aov(formula) analysis of variance model anova(fit,...) analysis of variance (or deviance) tables for one or more ﬁtted model objects density(x) kernel density estimates of x binom.test(), pairwise.t.test(), power.t.test(), prop.test(), t.test(), ... use help.search(&quot;test&quot;) Distributions rnorm(n, mean=0, sd=1) Gaussian (normal) rexp(n, rate=1) exponential rgamma(n, shap...
View Full Document

Ask a homework question - tutors are online