plot_splits: Plot Splits and Smoothed Model Fit

Description Usage Arguments Value Examples

View source: R/plot_splits.R

Description

Plot data with cut points for segments and smoothed model overlaid on observations.

Usage

1
plot_splits(cors_mods, ..., show_points = TRUE)

Arguments

cors_mods

List of lists of mods and cors of the form returned by running piececor::piecewise_cors().

...

Column names of variables of interest (unquoted), or a tidy selection specification (see: https://dplyr.tidyverse.org/reference/select.html). Only specify for those results you wish to plot.

show_points

Logical. Default is TRUE. Whether to include points in the graph or not. If you have lots of observations, you may want to set to FALSE.

Value

Plots of smoothing functions and splits between segments of observations on observations for each variable specified in ... (on x axis, .target variable will be on y). Red line is smoothed fit Blue lines are minima / maxima of smoothed fit / breakpoints in segments. Grey points are observations (assuming show_points = TRUE). Labels are cor values for each segment.

Examples

1
# See README

brshallo/piececor documentation built on Dec. 19, 2021, 11:49 a.m.