dynr.ggplot: The ggplot of the smoothed state estimates and the most likely regimes

Description

The ggplot of the smoothed state estimates and the most likely regimes

Usage

1
2
3
4
dynr.ggplot(res, dynrModel, style = 1, numSubjDemo = 2, idtoPlot = c(),
  names.state, names.observed, names.regime, shape.values, title, ylab,
  is.bw = FALSE, colorPalette = "Set2", fillPalette = "Set2",
  mancolorPalette, manfillPalette, ...)

Arguments

res

The dynr object returned by dynr.cook().

dynrModel

The model object to plot.

style

The style of the plot. If style is 1 (default), user-selected smoothed state variables are plotted. If style is 2, user-selected observed-versus-predicted values are plotted.

numSubjDemo

The number of subjects to be randomly selected for plotting.

idtoPlot

Values of the ID variable to plot

names.state

(optional) The names of the states to be plotted, which should be a subset of the state.names slot of the measurement slot of dynrModel.

names.observed

(optional) The names of the observed variables to be plotted, which should be a subset of the obs.names slot of the measurement slot of dynrModel.

names.regime

(optional) The names of the regimes to be plotted, which can be missing.

shape.values

(optional) A vector of values that correspond to the shapes of the points, which can be missing. See the R documentation on pch for details on possible shapes.

title

(optional) A title of the plot.

ylab

(optional) The label of the y axis.

is.bw

Is plot in black and white? The default is FALSE.

colorPalette

A palette function for lines and dots that when called with a single integer argument (the number of levels in the scale) returns the values that they should take.

fillPalette

A palette function for blocks that when called with a single integer argument (the number of levels in the scale) returns the values that they should take.

mancolorPalette

(optional) A color palette for manually scaling the colors of lines and plots.

manfillPalette

(optional) A color palette for manually scaling the colors of filled blocks.

...

A list of element name, element pairings that modify the existing ggplot2::ggplot ggplot2::theme. Consult the ggplot2::theme() function in the R package ggplot2::ggplot.


Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.