plotSeeds: Plot method for simulations

Description Usage Arguments Note Examples

Description

This method plots the simulation for every seed in the input. Continous variables are plotted as line plots, discrete variables in a stacked barplot beneath. The plot is created with ggplot2 and can be modified afterwards.

Usage

1
2
3
4
5
6
7
plotSeeds(x, seeds, ...)

## S3 method for class 'multSimData'
plotSeeds(x, seeds = NULL, ylim, ...)

## S3 method for class 'multSim'
plotSeeds(x, seeds, ...)

Arguments

x

object of class multSim or multSimData.

seeds

vector with seed numbers to plot. This is optional if x is a multSimData object.

...

additional arguments, currently not used.

ylim

a length-2 numeric defining the scale of the y-axis.

Note

A maximal number of 4 seeds can be plotted. The method requires the package tidyr.

Examples

1
2
3
4
data("toggleSwitch")
msim <- multSim(toggleSwitch, seeds = 1:2)
plotSeeds(msim)
plotSeeds(msim, seeds = 1) + ggplot2::facet_grid(variable ~ seed)

CharlotteJana/pdmpsim documentation built on July 2, 2019, 5:37 a.m.