View source: R/compare_weights.R
| plot_weights | R Documentation |
Two plots to compare coupling measures, in the spirit of the histograms and scatterplots of \insertCiteshen2019biblionetwork:
type = "distribution": one histogram of the weights per measure, each
with its own horizontal scale (the measures do not share a scale);
type = "scatter": the ranks of the pairs of nodes according to two
measures (x and y). Points on the diagonal are ranked identically by
both measures; ranks, rather than raw weights, are used because the
scales differ.
It needs the ggplot2 and scico packages.
plot_weights(
edges,
type = c("distribution", "scatter"),
x = NULL,
y = NULL,
bins = 50
)
edges |
A named list of edge tables, for instance from
|
type |
|
x, y |
For |
bins |
Number of bins of the histograms. |
A ggplot object.
Other tools to compare coupling measures:
compute_couplings(),
correlate_weights(),
merge_weights(),
overlap_top_weights(),
summarise_weights()
library(biblionetwork)
edges <- compute_couplings(Ref_stagflation, "Citing_ItemID_Ref", "ItemID_Ref",
weight_threshold = 2)
plot_weights(edges)
plot_weights(edges, type = "scatter", x = "angle", y = "strength")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.