Node connectivity {cheddar} | R Documentation |
Node connectivity
Description
Functions that report the connectivity of nodes in a food web.
Usage
IsBasalNode(community)
IsTopLevelNode(community)
IsIntermediateNode(community)
IsIsolatedNode(community)
IsConnectedNode(community)
IsNonBasalNode(community)
IsNonTopLevelNode(community)
BasalNodes(community)
TopLevelNodes(community)
IntermediateNodes(community)
IsolatedNodes(community)
ConnectedNodes(community)
NonTopLevelNodes(community)
NonBasalNodes(community)
FractionBasalNodes(community)
FractionIntermediateNodes(community)
FractionTopLevelNodes(community)
FractionIsolatedNodes(community)
FractionNonBasalNodes(community)
FractionConnectedNodes(community)
FractionNonTopLevelNodes(community)
Arguments
community |
an object of class |
Details
Each node in a community is defined as:
isolated | No resources or consumers, other than possibly itself |
basal | No resources and one or more consumers |
top-level | One or more resources and no consumers, other than possibly itself |
intermediate | Nodes not fitting any of the above categories |
These definitions allow the following additional definitions:
connected | basal, intermediate or top-level |
non-basal | isolated, intermediate or top-level |
non-top-level | isolated, basal or intermediate |
For each of the above seven definitions, ‘X’, there are three functions:
IsX
, X
and FractionX
.
The first returns a vector of logical
of length NumberOfNodes
;
values are TRUE
for nodes that fit the definition of ‘X’.
The second returns the names of nodes for which IsX
returns TRUE
.
The third returns the proportion of nodes in the community that fit the
definition of ‘X’.
Value
Either a logical
vector of length NumberOfNodes
or a
vector of names.
Author(s)
Lawrence Hudson
See Also
NumberOfNodes
,
Cannibals
,
IsCannibal
,
NumberOfTrophicLinks
,
PredationMatrix
,
Degree
,
InDegree
,
OutDegree
,
ResourcesByNode
,
ConsumersByNode
,
ResourcesOfNodes
,
ConsumersOfNodes
Examples
data(TL84)
# Assemble a table of node connectivity. Only one of each of the following
# four properties is TRUE for each node.
connectivity <- NPS(TL84, c('IsBasalNode', 'IsIsolatedNode',
'IsIntermediateNode', 'IsTopLevelNode'))
connectivity
# Each row sums to 1, confirming that exactly one of the columns in each row
# is TRUE.
all(1==rowSums(connectivity))
# These summations are 1
sum(FractionBasalNodes(TL84),
FractionIntermediateNodes(TL84),
FractionTopLevelNodes(TL84),
FractionIsolatedNodes(TL84))
sum(FractionConnectedNodes(TL84),
FractionIsolatedNodes(TL84))
sum(FractionBasalNodes(TL84),
FractionNonBasalNodes(TL84))
sum(FractionTopLevelNodes(TL84),
FractionNonTopLevelNodes(TL84))