plot.Mfx: plot method for objects of class 'Mfx'

Description Usage Arguments Details Examples

View source: R/Mfx_functions.R

Description

plot method for objects of class Mfx

Usage

1
2
3
## S3 method for class 'Mfx'
plot(mfx, type = c("response", "derivative"),
  centered = FALSE, ...)

Arguments

mfx

an object of class Mfx

type

one of either "response" or "derivative" depending on whether you want to plot ICE curves of the response or derivative function

centered

if type = "response" logical indicating whether or not to center the ICE curves to be 0 at their inital value

...

other parameters to be passed to plot

Details

marginal effects are plotted using individual conditional expectation (ICE) curves in the flavor of ice. The (default) gray curves are ICE curves. The green dashed curve is the mean curve. The red solid line is the linear projection given by the marginal effect.

If centered = TRUE, the curves are centered at their initial values where x = min(x).

If type = "derivative", the derivatives of ICE curves are plotted. There is no centered = TRUE analogue.

Points are also plotted. If you want a derivative or centered ICE curve, the actual data points are adjusted and plotted on the lines as well.

Examples

1
# TO DO

TommyJones/marginal documentation built on Nov. 21, 2019, 3:53 p.m.