calEquation {predict3d}R Documentation

calculated slope and intercept from object of class lm

Description

calculated slope and intercept from object of class lm

Usage

calEquation(
  fit,
  mode = 1,
  pred = NULL,
  modx = NULL,
  modx.values = NULL,
  label = NULL,
  maxylev = 6,
  digits = 2
)

Arguments

fit

An object of class lm

mode

A numeric

pred

name of predictor variable

modx

name of modifier variable

modx.values

Numeric. Values of modifier variable

label

A character string

maxylev

maximum length of unique value of variable to be treated as a categorial variable

digits

Integer indicating the number of decimal places

Examples

fit=lm(mpg~wt*hp+carb,data=mtcars)
calEquation(fit)
calEquation(fit,pred="hp")

[Package predict3d version 0.1.5 Index]