Learn R Programming

Momocs (version 1.4.1)

coo_oscillo: Momocs' 'oscilloscope' for Fourier-based approaches

Description

Shape analysis deals with curve fitting, whether \(x(t)\) and \(y(t)\) positions along the curvilinear abscissa and/or radius/tangent angle variation. These functions are mainly intended for (self-)teaching of Fourier-based methods.

Usage

coo_oscillo(
  coo,
  method = c("efourier", "rfourier", "tfourier", "all")[4],
  shape = TRUE,
  nb.pts = 12
)

Value

the plotted values

Arguments

coo

A list or a matrix of coordinates.

method

character among c('efourier', 'rfourier', 'tfourier', 'all'). 'all' by default

shape

logical whether to plot the original shape

nb.pts

integer. The number or reference points, sampled equidistantly along the curvilinear abscissa and added on the oscillo curves.

See Also

exemplifying functions

Examples

Run this code
coo_oscillo(shapes[4])
coo_oscillo(shapes[4], 'efourier')
coo_oscillo(shapes[4], 'rfourier')
coo_oscillo(shapes[4], 'tfourier')
#tfourier is prone to high-frequency noise but smoothing can help
coo_oscillo(coo_smooth(shapes[4], 10), 'tfourier')

Run the code above in your browser using DataLab