coo_ruban: Plots differences as (colored) segments aka a ruban

View source: R/gr-domesticplotters.R

coo_rubanR Documentation

Plots differences as (colored) segments aka a ruban

Description

Useful to display differences between shapes

Usage

coo_ruban(coo, dev, palette = col_heat, normalize = TRUE, ...)

Arguments

coo

a shape, typically a mean shape

dev

numeric a vector of distances or anythinh relevant

palette

the color palette to use or any palette

normalize

logical whether to normalize (TRUE by default) distances

...

other parameters to fed segments, eg lwd (see examples)

Value

a plot

See Also

Other plotting functions: coo_arrows(), coo_draw(), coo_listpanel(), coo_lolli(), coo_plot(), ldk_chull(), ldk_confell(), ldk_contour(), ldk_labels(), ldk_links(), plot_devsegments(), plot_table()

Other plotting functions: coo_arrows(), coo_draw(), coo_listpanel(), coo_lolli(), coo_plot(), ldk_chull(), ldk_confell(), ldk_contour(), ldk_labels(), ldk_links(), plot_devsegments(), plot_table()

Examples

ms <- MSHAPES(efourier(bot , 10), "type")
b <- ms$shp$beer
w <- ms$shp$whisky
# we obtain the mean shape, then euclidean distances between points
m <- MSHAPES(list(b, w))
d <- edm(b, w)
# First plot
coo_plot(m, plot=FALSE)
coo_draw(b)
coo_draw(w)
coo_ruban(m, d, lwd=5)

#Another example
coo_plot(m, plot=FALSE)
coo_ruban(m, d, palette=col_summer2, lwd=5)

#If you want linewidth rather than color
coo_plot(m, plot=FALSE)
coo_ruban(m, d, palette=col_black)

vbonhomme/Momocs documentation built on Nov. 13, 2023, 8:54 p.m.