Learn R Programming

foodweb (version 1-0)

plotweb: Plot a Food Web Analysed Using the analyse.single() Function

Description

Produces a three dimensional, coloured plot from data provided as a binary, ordered predator-prey matrix. The matrix needs to have been analysed with the function analyse.single() in order for this function to work.

Usage

plotweb(cols, radii)

Arguments

cols
a list of colours, one per trophic level in the food web. Any colour name found is colours() or colors() is allowed. See colours() and colors()
radii
a list of radii, one per trophic level in the food web.

Value

A three dimensional plot of a food web network, as generated using plot3d of the package rgl.

Details

Angle of orientation of the plot can be manipulated by click, drag and drop operations directly on the graphics device. Zoom can be manipulated with the mouse wheel while the graphics device is active.

References

Perdomo G., Sunnucks P. and Thompson R.M. (submitted). food web: an open-source program for the visualisation and analysis of compilations of complex food webs. Environmental Modelling and Software.

See Also

analyse.single analyse.list analyse.seq mat.2.list

Examples

Run this code
## Not run: 
# data(moss)
# write.table(moss, file = "moss.csv", append=FALSE, sep=",", col.names=FALSE, row.names=FALSE)
# analyse.single(filename="moss.csv")
# plotweb(col=c("red", "green", "blue", "yellow"), radii=c(5,10,12,12))
# ## End(Not run)

Run the code above in your browser using DataLab