IntensityFunctionPlot: Plot intensity function

View source: R/IntensityFunctionPlot.R

IntensityFunctionPlotR Documentation

Plot intensity function

Description

Plots the estimated intensity function along with a 95% bootstrap quantile confidence interval.

Usage

IntensityFunctionPlot(
  model.estimates,
  model.number,
  best.models,
  add.title = F,
  filename = NULL,
  neuron.name = NULL,
  time.resolution = NULL,
  y.limits = NULL,
  axis.label.size = 18,
  title.size = 24,
  IC.type = NULL,
  RStudio = FALSE
)

Arguments

model.estimates

a list containing all intensity function estimates and corresponding parameter estimates for all models. This list is typically generated by the EstimateThetaT() function.

model.number

a scalar containing the index of the model to plot in the model.estimates list.

best.models

a list containing the names and corresponding indices of all models in the model.estimates list. This argument is used for titling the plot(s).

add.title

whether to add a title to the plot(s).

filename

optionally, the name of a graphics or pdf file in which to save the plot(s). If no file extension is specified, plots will be saved to a pdf file. If filename is NULL, then each plot is output to a new graphics device.

neuron.name

a string containing the name of the neuron being plotted, used only in the output file metadata.

time.resolution

a numeric vector indicating the interval between time points (ticks) on the x-axis of the plot.

y.limits

a numeric vector containing the minimum and maximum amplitude on the y-axis of the plot.

axis.label.size

a scalar determining the font size of the x- and y-axis labels of the plot.

title.size

a scalar determining the font size of the title of the plot (if one exists).

IC.type

optionally, the information criterion used to identify the best model; only used for titling the plot. By default this is NULL, indicating all models are plotted prior to model selection.

RStudio

whether this function is being run in RStudio. This is only used if plots are output to R graphics devices, as RStudio opens graphics devices differently than R using Console/Terminal.

Value

A list of ggplot objects, each of which contains the parameters necessary to produce one intensity function plot.


dpwynne/mmnst documentation built on Aug. 1, 2023, 8:08 a.m.