Learn R Programming

ndtv (version 0.13.4)

filmstrip: Create a `small multiples` plot of a networkDynamic object.

Description

Plots several frames of a network animation of a networkDynamic object in a single static image as a way to provide a quick visual summary of the dynamics of the network.

Usage

filmstrip(nd, frames = 9, slice.par, render.par, mfrow, verbose = FALSE, ...)

Value

Generates plots on the active graphics device.

Arguments

nd

networkDynamic object to be plotted

frames

integer number of frames to extract and render

slice.par

optional list of parameters to control binning of network, overrides frames argument. See compute.animation

render.par

optional list of parameters to control rendering of network. See render.animation

mfrow

optional two-element numeric vector giving the number of rows and columns for the layout grid. See par.

verbose

boolean,(defaults to FALSE) verbose argument to be passed to compute.animationrender.animation/

...

additional arguments to be passed to plot.network via render.animation

Author

skyebend

Details

If the networkDynamic object does not already have animation coordinates, calls compute.animation to calculate coordinates for the appropriate number of frames. The frames argument determines the number of evenly-spaced network slices to be rendered by render.animation (with the normal plot recording disabled) as images on the final plot grid. Note that if the layout has coordinates pre-computed by compute.animation, the slices selected by the frames argument may not align exactly with the previously compute slices. Passing in a slice.par argument will overide frames to determine exactly which slices will be rendered.

The layout of plot grid can be changed via the mfrow argument.

See Also

See also compute.animation, render.animation.

Examples

Run this code
data(stergm.sim.1)
filmstrip(stergm.sim.1,displaylabels=FALSE)
# print an overall title for the main plot
title('stergm.sim.1 at 9 time points')

# adjust margins of individual plots to make more room
par(mar=c(1,1,1,1))
filmstrip(stergm.sim.1)

Run the code above in your browser using DataLab