find.ranks: make food trophic ranks for all the species in the matrix for...

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/loop.R

Description

it will return trophic ranks of species in the food webs

Usage

1
find.ranks(gemat, converted = TRUE)

Arguments

gemat

gemat is a square matrix

converted

if TRUE, resultant trophic ranks of species will be converted to a list, which is the input format for fplot.foodweb() function; if FALSE, resultant trophic ranks of species are present in a vector default is TRUE

Value

it will return a list (converted=TRUE), each list represent one trophic rank, the elements of which are the species being classified into the rank. it can also return a vector (converted=FALSE), each element denote the rank of the species.

Author(s)

Youhua Chen <haydi@126.com>

References

Chen Y (2012) loop: an R package for performing decomposition of weighted directed graphs, food web analysis and flexible network plotting. Submitted.

See Also

fplot.foodweb

Examples

1
2
3
gemat<-matrix(c(0,5,3,7,0,5,0,8,0,4,3,8,0,1,6,7,0,1,0,2,0,4,6,2,0),5,5)
ranks<-find.ranks(gemat)
fplot.foodweb(gemat=gemat,ranks=ranks,addlabels=TRUE,bg="white",pch=21,pcex=4,lcol=2,weighted=FALSE)

loop documentation built on May 2, 2019, 9:07 a.m.