Learn R Programming

lares (version 4.8.4)

plot_chord: Chords Plot

Description

This function plots discrete and continuous values results

Usage

plot_chord(
  origin,
  dest,
  weight = 1,
  mg = 3,
  title = "Chord Diagram",
  subtitle = "",
  pal = NA
)

Arguments

origin, dest

Vectors. Origin and destination vectors

weight

Vector. Weight for each chor

mg

Numeric. Margin adjust for plot in case of need

title

Character. Title for the plot

subtitle

Character. Subtitle for the plot

pal

Vector. Colour pallete. Order matters.

See Also

Other Visualization: distr(), freqs_df(), freqs_list(), freqs_plot(), freqs(), gg_bars(), gg_pie(), noPlot(), plot_survey(), plot_timeline(), summer(), theme_lares2(), theme_lares(), tree_var()

Examples

Run this code
# NOT RUN {
df <- data.frame(from = c(1, 1, 2, 3, 4, 1, 6), to = c(4, 4, 4, 2, 2, NA, NA))
plot_chord(df$from, df$to)
# }

Run the code above in your browser using DataLab