pareto | R Documentation |
Plots a graph of the percentage of more connected nodes as a function of the percentage of the total (weighted) indegree and outdegree.
pareto( A, xlabel = "More connected nodes (%)", ylabel = "% of total", legin = "in", legout = "out" )
A |
An adjacency |
xlabel |
The text for the x-axis label. |
ylabel |
The text for the y-axis label. |
legin |
The text for the legend of the indegree. |
legout |
The text for the legend of the outdegree. |
This function sorts in decreasing order the indegree and outdegree of the nodes of a network. Then the function calculates the percentage of more connected nodes and the corresponding percentage of the total indegree and outdegree. The indegree and outdegree can be weighted or not, depending on the adjacency matrix provided by the user.
A graph of the percentage of more connected nodes as a function of the percentage of the total (weighted) indegree and outdegree for the user to check if the 80-20 rule (Pareto principle) applies to the analyzed network.
[1] Negreiros RL, Grisi-Filho JHH, Dias RA, Ferreira F, Ferreira Neto JS, Ossada R, Amaku M (2020). "Analysis of the Cattle Trade Network in the State of Mato Grosso, Brazil." Brazilian Journal of Veterinary Research and Animal Science, 57 (4), e171635. doi: /10.11606/issn.1678-4456.bjvras.2020.171635
# Generate an arbitrary 100 by 100 adjacency matrix with zeros and ones # Remove loops A <- matrix(rbinom(100 * 100, 1, 0.2), ncol = 100, nrow = 100) diag(A) <- 0 # Call function pareto(A)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.