plot.drop_term: drop_term plot method

Description Usage Arguments Value Examples

View source: R/stepAIC_BIC.R

Description

drop_term plot method

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## S3 method for class 'drop_term'
plot(
  x,
  ...,
  horiz = TRUE,
  las = ifelse(horiz, 1, 2),
  col = c("#DF536B", "#2297E6"),
  border = c("#DF536B", "#2297E6"),
  show.model = TRUE
)

Arguments

x

An object of class "drop_term" generated by tither drop_term or add_term

..., horiz

arguments past on to graphics::barplot

las

graphics parameter

col, border

barplot fill and border colour(s) for positive and negative changes to the criterion, respectively

show.model

logical: should the model itself be displayed?

Value

x invisibly

Examples

1
2
3
4
5
boston_quad <- lm(medv ~ . + (rm + tax + lstat)^2 + poly(rm, 2) + 
         poly(tax, 2) + poly(lstat, 2), Boston)
dboston_quad <- drop_term(boston_quad, k = "bic")
plot(dboston_quad)
plot(dboston_quad, horiz = FALSE)

BillVenables/MASSExtra documentation built on March 8, 2021, 7:18 p.m.