modelfit: Summarize linear model fit.

Description Usage Arguments Value Examples

Description

Summarize linear model fit.

Usage

1
modelfit(DF, yvar = "pm", xvar = "aod47", verbose = TRUE, digits = 2)

Arguments

DF

a data.frame

yvar

character vector of the column name for outcome

xvar

character vector of the column name(s) for predictor(s)

verbose

logical whether to print summary

digits

integer number of digits to print (if verbose is equal to FALSE, this parameter is not considered)

Value

a data.frame of the r-squared and the rmse for the linear regression

Examples

1
2
test <- data.frame(x = 1:100, y = 1:100 + rnorm(100))
modelfit(test, yvar = "y", xvar = "x")

allanjust/aodlur documentation built on May 10, 2019, 9:22 a.m.