Returns a series of descriptive statistics for a fragmentation graph.
frag.get.parameters(graph, layer.attr, verbose=TRUE)
A list of parameters values (n.components, vertices, edges, balance, components.balance, disturbance, aggreg.factor, planar, edge.weights.sum, edge.weights.median, edge.weights.median.abs.dev.).
An igraph
undirected graph.
Character. The name of the vertices attribute giving the spatial unit of each fragment (e.g. layer).
Logical. Whether to print or not warning messages.
Sebastien Plutniak <sebastien.plutniak at posteo.net>
This function is a convenient function to get general information about a fragmentation graph. It is particularly useful for setting the parameters of the frag.simul.process
function.
It returns:
n.components: number of objects (i.e. connected components)
vertices: number of fragments
edges: number of connection relationships between fragments
balance: estimated fragments balance, i.e. proportion of fragments in the first spatial unit (see details)
components balance: estimated objects balance, i.e. proportion of objects in the first spatial unit (see details)
disturbance: estimated disturbance, i.e. proportion of fragments which moved between spatial units (see details)
aggreg.factor: aggregation factor, diversity of the components' edge count (see details)
planar: whether the graph is planar or not
edge.weights.sum: sum of the edge weights
edge.weights.median: median of the edge weights
edge.weights.median.abs.dev.: median absolute deviation of the edge weights
The (fragments) balance and components balance are calculated from the subgraph including only the fragments connected to fragments from the same spatial unit. This is to approximate these proportions of deposited materials regardless the effects of posterior disturbances. Results are given about the spatial unit whose label comes first alphanumerically.
When studying a pair of spatial units, disturbance is defined as the proportion of fragments which moved from their initial spatial unit to the other spatial unit. This definition is used in the frag.process.simul
function to generate random fragmentation graphs.
However, frag.get.parameters
uses a different definition since its aim is different: considering a fragmentation graph representing the result of unknown post-depositional processes, frag.get.parameters
returns an estimation of the disturbance which might happened. This estimation is computed from a subgraph including only the components with fragments from the two spatial units: disturbance is get from the number of fragments belonging to the less represented spatial unit in this subgraph over the total number of fragments in the subgraph.
The aggregation factor reflects the diversity of the components' edge count. The factor is calculated by: $$1 - 1/(1 + sd(components\ edge\ count))$$
The optional RBGL package is required to determine the planarity of the graph. If it is not installed, the planar
argument is set to FALSE by default.
g <- frag.simul.process(n.components=20, vertices=50, disturbance=0.1)
frag.get.parameters(g, "layer")
Run the code above in your browser using DataLab