gg_rsm {ggDoE}R Documentation

Contour plot(s) of a fitted linear model in ggplot2

Description

Contour plot(s) of a fitted linear model in ggplot2

Usage

gg_rsm(
  rsm_model,
  formula,
  decode = FALSE,
  n_columns = 2,
  text_size = 3,
  bins = 6,
  ...
)

Arguments

rsm_model

Model of class "rsm"

formula

A formula, or a list of formulas

decode

This has an effect only if x is an rsm object or other model object that supports coded.data. In such cases, if decode is TRUE, the coordinate axes are transformed to their decoded values.

n_columns

number of columns for grid layout. Default is 2

text_size

size of text for labelled contour lines. Default is 3

bins

Number of contour bins. Overridden by binwidth

...

Other arguments passed on to contour(). For help with more arguments see ?rsm::contour.lm

Value

A grid of contour plot(s) of a fitted linear model in 'ggplot2'

Examples

## Not run: 
heli.rsm <- rsm::rsm(ave ~ SO(x1, x2, x3),data = rsm::heli)

gg_rsm(heli.rsm,formula = ~x1+x2+x3,at = rsm::xs(heli.rsm),n_columns=3)


## End(Not run)

[Package ggDoE version 0.8 Index]