Momocs: Morphometrics using R

A complete toolkit for morphometrics, from data extraction to multivariate analyses. Most common 2D morphometrics approaches are included: outlines, open outlines, configurations of landmarks, traditional morphometrics, and facilities for data preparation, manipulation and visualization with a consistent grammar throughout. Momocs allows reproducible, complex morphometric analyses, paves the way for a pure open-source workflow in R, and other morphometrics approaches should be easy to plug in, or develop from, on top of this canvas.

AuthorVincent Bonhomme [aut, cre], Julien Claude [aut]
Date of publication2016-10-25 23:37:38
MaintainerVincent Bonhomme <>
LicenseGPL-2 | GPL-3

View on CRAN

Man pages

a2l: Converts an array of coordinates to a list of matrices

a2m: Converts an array of coordinates to a matrix

add_ldk: Adds new landmarks on Out and Opn objects

arrange: Arranges (ala dplyr) on Momocs objects

as_df: Converts Momocs objects to data.frames

as.Out: Convert an OutCoe object into an Out object

at_least: Retains group with at least a certain number of individuals

bezier: Calculates Bezier coefficients from a shape

bezier_i: Calculates a shape from Bezier coefficients

bind_db: Binds with a database

boxplot.OutCoe: Boxplot of morphometric coefficients

boxplot.PCA: Boxplot on PCA objects

breed: Jitters Coe (and others) objects

calibrate_deviations: Quantitative calibration, through deviations, for Out and Opn...

calibrate_harmonicpower: Quantitative calibration, through harmonic power, for Out and...

calibrate_r2: Quantitative r2 calibration for Opn objects

calibrate_reconstructions: Calibrate using reconstructed shapes

chc2Out: Converts chain-coded coordinates to Out object

chc2pix: Converts chain-coded coordinates to (x; y) coordinates

chop: Chops (rough slicing) Momocs objects

classify: Classify using LDA

CLUST: Hierarchical clustering

Coe: Coe "super" class

coeff_sel: Helps to select a given number of harmonics from a numerical...

coeff_split: Converts a numerical description of harmonic coefficients to...

color_palettes: Some color palettes

colors_transp: Transparency helpers and palettes

combine: Combines Momocs objects

conf_ell: Confidence ellipses

Coo: Coo "super" class

coo_align: Aligns coordinates

coo_aligncalliper: Aligns shapes along their 'calliper length'

coo_alignminradius: Aligns shapes using their shortest radius

coo_alignxax: Aligns shapes along the x-axis

coo_area: Calculates the area of a shape

coo_arrows: Plots (lollipop) differences between two configurations

coo_baseline: Register new baselines

coo_bookstein: Register Bookstein's coordinates

coo_calliper: Calculates the calliper length

coo_centdist: Returns the distance between everypoints and the centroid

coo_center: Centers coordinates

coo_centpos: Calculate centroid coordinates

coo_centsize: Calculates centroid size

coo_check: Checks shapes

coo_chull: Calculates the convex hull of a shape

coo_circularity: Calculates the circularity of a shape

coo_circularityharalick: Calculates the Haralick's circularity of a shape

coo_circularitynorm: Calculates the 'normalized' circularity of a shape

coo_close: Closes/uncloses shapes

coo_convexity: Calculates the convexity of a shape

coo_down: coo_down —- Retains coordinates with negative y-coordinates

coo_draw: Adds a shape to the current plot

coo_dxy: Calculate abscissa and ordinate on a shape

coo_eccentricityboundingbox: Calculates the eccentricity (bounding box) of a shape

coo_eccentricityeigen: Calculates the eccentricity (using eigenvalues) of a shape

coo_elongation: Calculates the elongation of a shape

coo_extract: Extract coordinates from a shape

coo_flip: Flips shapes

coo_force2close: Forces shapes to close

coo_interpolate: Interpolates coordinates

coo_jitter: Jitters shapes

coo_ldk: Defines landmarks interactively

coo_left: Retains coordinates with negative x-coordinates

coo_length: Calculates the length of a shape

coo_listpanel: Plots sets of shapes.

coo_lolli: Plots (lollipop) differences between two configurations

coo_lw: Calculates length and width of a shape

coo_nb: Counts coordinates

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

coo_perim: Calculates the perimeter

coo_perimcum: Calculates the cumulative chordal distance along a shape.

coo_perimpts: Calculates the chordal distance along a shape.

coo_plot: Plots a single shape

coo_rectangularity: Calculates the rectangularity of a shape

coo_rectilinearity: Calculates the rectilinearity of a shape

coo_rev: Reverses coordinates

coo_right: Retains coordinates with positive x-coordinates

coo_rotate: Rotates coordinates

coo_rotatecenter: Rotates shapes with a custom center

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

coo_sample: Sample coordinates (among points)

coo_samplerr: Samples coordinates (regular radius)

coo_scale: Scales coordinates

coo_scalexy: Shrinks coordinates in one direction

coo_shear: Shears shapes

coo_slice: Slices shapes between successive coordinates

coo_slide: Slides coordinates

coo_slidedirection: Slides coordinates in a particular direction

coo_slidegap: Slides coordinates using the widest gap

coo_smooth: Smoothes coordinates

coo_smoothcurve: Smoothes coordinates on curves

coo_solidity: Calculates the solidity of a shape

coo_tangle: Calculates the tangent angle along the perimeter of a shape

coo_template: 'Templates' shapes

coo_theta3: Calculate the angle formed by three (x; y) coordinates

coo_thetapts: Calculates the angle of every edge of a shape

coo_trans: Translates coordinates

coo_trim: Trims both ends coordinates from shape

coo_trimbottom: Trims bottom coordinates from shape

coo_trimtop: Trims top coordinates from shape

coo_up: Retains coordinates with positive y-coordinates

coo_width: Calculates the width of a shape

d: A wrapper to calculates euclidean distances between two...

data_bot: Data: Outline coordinates of beer and whisky bottles.

data_chaff: Data: Landmark and semilandmark coordinates on cereal glumes

data_charring: Data: Outline coordinates from an experimental charring on...

data_flower: Data: Measurement of iris flowers

data_hearts: Data: Outline coordinates of hand-drawn hearts

data_molars: Data: Outline coordinates of 360 molars

data_mosquito: Data: Outline coordinates of mosquito wings.

data_oak: Data: Configuration of landmarks of oak leaves

data_olea: Data: Outline coordinates of olive seeds open outlines.

data_shapes: Data: Outline coordinates of various shapes

data_trilo: Data: Outline coordinates of cephalic outlines of trilobite

data_wings: Data: Landmarks coordinates of mosquito wings

def_ldk: Defines new landmarks on Out and Opn objects

def_links: Defines links between landmarks

def_slidings: Defines sliding landmarks matrix

dfourier: Discrete cosinus transform

dfourier_i: Investe discrete cosinus transform

dfourier_shape: Calculates and draws 'dfourier' shapes

dissolve: Dissolves Coe objects

ed: Calculates euclidean distance between two points.

edi: Calculates euclidean intermediate between two points.

edm: Calculates euclidean distance every pairs of points in two...

edm_nearest: Calculates the shortest euclidean distance found for every...

efourier: Elliptical Fourier transform

efourier_i: Inverse elliptical Fourier transform

efourier_norm: Normalizes harmonic coefficients.

efourier_shape: Calculates and draw 'efourier' shapes.

export: Exports Coe objects and shapes

fgProcrustes: Full Generalized Procrustes alignment between shapes

fgsProcrustes: Full Generalized Procrustes alignment between shapes with...

filter: Filters (ala dplyr) on Momocs objects

fProcrustes: Full Procrustes alignment between two shapes

get_chull_area: Calculates convex hull area/volume of PCA scores

get_ldk: Retrieves landmarks coordinates

get_pairs: Get paired individual on a Coe, PCA or LDA objects

get_slidings: Extracts sliding landmarks coordinates

harm.contrib: Harmonic contribution to shape

harm_pow: Calculates harmonic power given a list from e/t/rfourier

hist.OutCoe: Histogram of morphometric coefficients

img_plot: Plots a .jpg image

import_Conte: Extracts outlines coordinates from an image silhouette

import_jpg: Extracts outline coordinates from multiple .jpg files

import_jpg1: Extracts outline coordinates from a single .jpg file

import_StereoMorph: Imports files creates by StereoMorph into Momocs

import_tps: Imports a tps file

import_txt: Imports coordinates from a .txt file

is: Various class/component testers

is_closed: Tests if shapes are closed


l2a: Converts a list of coordinates to an array of coordinates

l2m: Converts a list of coordinates to a matrix of coordinates.

LDA: Linear Discriminant Analysis on Coe objects

Ldk: Builds an Ldk object

ldk_check: Checks 'ldk' shapes

ldk_chull: Draws convex hulls around landmark positions

ldk_confell: Draws confidence ellipses for landmark positions

ldk_contour: Draws kernel density contours around landmark

ldk_labels: Add landmarks labels

ldk_links: Draws links between landmarks

lf_structure: Extracts structure from filenames

links_all: Creates links (all pariwise combinations) between landmarks

links_delaunay: Creates links (Delaunay triangulation) between landmarks

m2a: Converts a matrix of coordinates to an array of coordinates

m2d: Converts a matrix of coordinates to a data.frame

m2l: Converts a matrix of coordinates to a list of coordinates.

m2ll: Converts a matrix of coordinates into a list of matrices

MANOVA: Multivariate analysis of (co)variance on Coe objects

MANOVA_PW: Pairwise Multivariate analyses of variance

measure: Measures shape descriptors

Momocs: Momocs

Momocs_help: Browse Momocs online doc

Momocs_lastversion: Install and load the last version of Momocs

Momocs_version: Get Momocs version

mshapes: Mean shape calculation for Coo, Coe, etc.

mutate: Mutates (ala dplyr) on Momocs objects

nef2Coe: Imports .nef to Coe objects

npoly: Calculate natural polynomial fits on open outlines

Ntable: Plots confusion matrix of sample sizes within $fac

ntsrow2Coo: Imports .nts to Coo objects

Opn: Builds an Opn object

OpnCoe: Builds an OpnCoe object

opoly: Calculate orthogonal polynomial fits on open outlines

Out: Builds an Out object

OutCoe: Builds an OutCoe object

panel2: Family picture of shapes (ggplot2)

panel.Coo: Family picture of shapes

PCA: Principal component analysis on Coe objects

PCcontrib: Shape variation along PC axes

perm: Permutes and breed Coe (and others) objects

pix2chc: Converts (x; y) coordinates to chaincoded coordinates

plot2.PCA: Plots Principal Component Analysis ala ggplot2

plot3.PCA: #' @describeIn plot.PCA #' @export mplot <- plot.PCA Plots a...

plot.Coo: Graphical inspection of shapes

plot_CV: Plots a cross-validation table as an heatmap

plot_CV2: Plots a cross-correlation table

plot_devsegments: Draws colored segments from a matrix of coordinates.

plot.LDA: Plots Linear Discriminant Analysis

plot.PCA: Plots Principal Component Analysis

poly_i: Calculates shape from a polynomial model

pos.shapes: Calculates nice positions on a plane for drawing shapes

pProcrustes: Partial Procrustes alignment between two shapes

Ptolemy: Ptolemaic ellipses and illustration of efourier

reexports: Objects exported from other packages

reLDA: "Redo" a LDA on new data

rename: Renames (ala dplyr) on Momocs objects

rePCA: "Redo" a PCA on a new Coe

rescale: Rescale coordinates from pixels to real length units

rfourier: Radii variation Fourier transform

rfourier_i: Inverse radii variation Fourier transform

rfourier_shape: Calculates and draw 'rfourier' shapes.

rm_asym: Removes asymmetric and symmetric variation on OutCoe objects

rm_harm: Removes harmonics from Coe objects

rm_uncomplete: Removes shapes with incomplete slices

rw_rule: Renames levels on Momocs objects

sample_frac: Samples a fraction of shapes in Momocs objects

sample_n: Samples n shapes on Momocs objects

scree: Methods for PCA eigen values

select: Selects (ala dplyr) on Momocs objects

slice: Slices (ala dplyr) on Momocs objects

slidings_scheme: Extracts partitions of sliding coordinates

stack2: Family picture of shapes (ggplot2)

stack.Coo: Family picture of shapes

subset: Subsets on Momocs objects

symmetry: Calcuates symmetry indices on OutCoe objects

table: Cross-tabulates objects

tfourier: Tangent angle Fourier transform

tfourier_i: Inverse tangent angle Fourier transform

tfourier_shape: Calculates and draws 'tfourier' shapes.

tie_jpg_txt: Binds .jpg outlines from .txt landmarks taken on them

tps2coo: Reads a single tps-like shape as lines

tps2d: Thin Plate Splines for 2D data

tps_arr: Deformation 'vector field' using Thin Plate Splines

tps_grid: Deformation grids using Thin Plate Splines

tps_iso: Deformation isolines using Thin Plate Splines.

tps_raw: Vanilla Thin Plate Splines

TraCoe: Traditional morphometrics class

transmute: Transmutes (ala dplyr) on Momocs objects

truss: Truss measurement

validate: Validates Coo objects

vecs_param: Some vector utilities.

which_out: Remove outliers on Coe

Files in this package

Momocs/R/mult-Manova.R Momocs/R/cl-farming.R Momocs/R/core-opn-bezier.R Momocs/R/mult-mshapes.R Momocs/R/gr-morphospaces2.R Momocs/R/core-out-efourier.R Momocs/R/cl-def-CooCoe.R Momocs/R/gr-PCA.R Momocs/R/coo-shapedescriptors.R Momocs/R/gr-Coe.R Momocs/R/mult-LDA.R Momocs/R/core-opn-polynomials.R Momocs/R/cl-def-Opn.R Momocs/R/core-premodern.R Momocs/R/cl-def-Out.R Momocs/R/pkg-datasets.R Momocs/R/core-out-tfourier.R Momocs/R/pkg-misc.R Momocs/R/mult-KMEANS.R Momocs/R/babel-export.R Momocs/R/cl-def-TraCoe.R Momocs/R/cl-validate.R Momocs/R/core-opn-dct.R Momocs/R/mult-PCA.R Momocs/R/Momocs-package.R Momocs/R/core-ldk-procrustes.R Momocs/R/core-outopn-calibrate.R Momocs/R/gr-Coo.R Momocs/R/gr-LDA.R Momocs/R/gr-morphospaces.R Momocs/R/coo-utilities.R Momocs/R/gr-PCA2.R Momocs/R/gr-themes.R Momocs/R/gr-TPS.R Momocs/R/cl-def-Ldk.R Momocs/R/babel-bridges.R Momocs/R/coo-ldk-utilities.R Momocs/R/cl-utilities.R Momocs/R/babel-import.R Momocs/R/cl-handling.R Momocs/R/gr-domesticplotters.R Momocs/R/core-out-rfourier.R Momocs/R/gr-misc.R Momocs/R/gr-layers.R Momocs/R/mult-clust.R
Momocs/man/dissolve.Rd Momocs/man/ldk_confell.Rd Momocs/man/coo_trimtop.Rd Momocs/man/rm_uncomplete.Rd Momocs/man/opoly.Rd Momocs/man/coo_smooth.Rd Momocs/man/coo_centsize.Rd Momocs/man/coo_thetapts.Rd Momocs/man/coo_rectilinearity.Rd Momocs/man/plot.Coo.Rd Momocs/man/panel.Coo.Rd Momocs/man/coo_ruban.Rd Momocs/man/a2m.Rd Momocs/man/reLDA.Rd Momocs/man/PCcontrib.Rd Momocs/man/rm_harm.Rd Momocs/man/sample_frac.Rd Momocs/man/boxplot.OutCoe.Rd Momocs/man/breed.Rd Momocs/man/tps2d.Rd Momocs/man/coo_check.Rd Momocs/man/def_ldk.Rd Momocs/man/CLUST.Rd Momocs/man/tps2coo.Rd Momocs/man/Out.Rd Momocs/man/coo_down.Rd Momocs/man/coo_up.Rd Momocs/man/boxplot.PCA.Rd Momocs/man/tps_grid.Rd Momocs/man/slidings_scheme.Rd Momocs/man/table.Rd Momocs/man/data_mosquito.Rd Momocs/man/Momocs_lastversion.Rd Momocs/man/data_olea.Rd Momocs/man/stack2.Rd Momocs/man/coo_centpos.Rd Momocs/man/tfourier_shape.Rd Momocs/man/transmute.Rd Momocs/man/chc2pix.Rd Momocs/man/fProcrustes.Rd Momocs/man/at_least.Rd Momocs/man/import_jpg1.Rd Momocs/man/data_wings.Rd Momocs/man/combine.Rd Momocs/man/coo_lolli.Rd Momocs/man/coo_alignxax.Rd Momocs/man/as_df.Rd Momocs/man/links_delaunay.Rd Momocs/man/def_links.Rd Momocs/man/ldk_chull.Rd Momocs/man/efourier.Rd Momocs/man/add_ldk.Rd Momocs/man/npoly.Rd Momocs/man/coo_eccentricityeigen.Rd Momocs/man/def_slidings.Rd Momocs/man/import_txt.Rd Momocs/man/dfourier.Rd Momocs/man/tps_iso.Rd Momocs/man/panel2.Rd Momocs/man/Momocs_version.Rd Momocs/man/Opn.Rd Momocs/man/validate.Rd Momocs/man/coo_flip.Rd Momocs/man/rfourier_i.Rd Momocs/man/get_pairs.Rd Momocs/man/mutate.Rd Momocs/man/coo_circularitynorm.Rd Momocs/man/a2l.Rd Momocs/man/edm.Rd Momocs/man/bezier_i.Rd Momocs/man/coo_shear.Rd Momocs/man/l2m.Rd Momocs/man/get_chull_area.Rd Momocs/man/coo_perim.Rd Momocs/man/OutCoe.Rd Momocs/man/import_StereoMorph.Rd Momocs/man/data_charring.Rd Momocs/man/coo_slidegap.Rd Momocs/man/coo_interpolate.Rd Momocs/man/dfourier_i.Rd Momocs/man/coo_plot.Rd Momocs/man/plot_devsegments.Rd Momocs/man/coo_left.Rd Momocs/man/data_shapes.Rd Momocs/man/Ptolemy.Rd Momocs/man/Momocs_help.Rd Momocs/man/MANOVA_PW.Rd Momocs/man/coo_slide.Rd Momocs/man/harm.contrib.Rd Momocs/man/coo_slice.Rd Momocs/man/symmetry.Rd Momocs/man/ldk_check.Rd Momocs/man/Ntable.Rd Momocs/man/chc2Out.Rd Momocs/man/coo_trim.Rd Momocs/man/coo_jitter.Rd Momocs/man/poly_i.Rd Momocs/man/color_palettes.Rd Momocs/man/classify.Rd Momocs/man/measure.Rd Momocs/man/coo_right.Rd Momocs/man/ldk_contour.Rd Momocs/man/KMEANS.Rd Momocs/man/coo_chull.Rd Momocs/man/coo_align.Rd Momocs/man/fgProcrustes.Rd Momocs/man/lf_structure.Rd Momocs/man/tfourier.Rd Momocs/man/links_all.Rd Momocs/man/img_plot.Rd Momocs/man/OpnCoe.Rd Momocs/man/coo_baseline.Rd Momocs/man/export.Rd Momocs/man/coo_calliper.Rd Momocs/man/as.Out.Rd Momocs/man/vecs_param.Rd Momocs/man/Coe.Rd Momocs/man/plot_CV.Rd Momocs/man/get_slidings.Rd Momocs/man/Ldk.Rd Momocs/man/rePCA.Rd Momocs/man/import_jpg.Rd Momocs/man/coo_perimpts.Rd Momocs/man/ldk_labels.Rd Momocs/man/plot2.PCA.Rd Momocs/man/coo_sample.Rd Momocs/man/coo_aligncalliper.Rd Momocs/man/efourier_norm.Rd Momocs/man/coo_center.Rd Momocs/man/tps_arr.Rd Momocs/man/coeff_sel.Rd Momocs/man/coo_ldk.Rd Momocs/man/conf_ell.Rd Momocs/man/d.Rd Momocs/man/import_tps.Rd Momocs/man/m2d.Rd Momocs/man/data_molars.Rd Momocs/man/coo_template.Rd Momocs/man/dfourier_shape.Rd Momocs/man/coo_oscillo.Rd Momocs/man/pix2chc.Rd Momocs/man/mshapes.Rd Momocs/man/coo_extract.Rd Momocs/man/data_trilo.Rd Momocs/man/coo_rotatecenter.Rd Momocs/man/get_ldk.Rd Momocs/man/reexports.Rd Momocs/man/stack.Coo.Rd Momocs/man/data_flower.Rd Momocs/man/coo_convexity.Rd Momocs/man/coo_rev.Rd Momocs/man/plot.PCA.Rd Momocs/man/calibrate_deviations.Rd Momocs/man/rfourier.Rd Momocs/man/coo_centdist.Rd Momocs/man/tfourier_i.Rd Momocs/man/arrange.Rd Momocs/man/perm.Rd Momocs/man/rename.Rd Momocs/man/fgsProcrustes.Rd Momocs/man/MANOVA.Rd Momocs/man/coo_lw.Rd Momocs/man/calibrate_harmonicpower.Rd Momocs/man/nef2Coe.Rd Momocs/man/coo_rotate.Rd Momocs/man/TraCoe.Rd Momocs/man/harm_pow.Rd Momocs/man/plot_CV2.Rd Momocs/man/data_chaff.Rd Momocs/man/coo_trans.Rd Momocs/man/data_hearts.Rd Momocs/man/efourier_i.Rd Momocs/man/rescale.Rd Momocs/man/ldk_links.Rd Momocs/man/which_out.Rd Momocs/man/coo_trimbottom.Rd Momocs/man/coeff_split.Rd Momocs/man/coo_perimcum.Rd Momocs/man/coo_area.Rd Momocs/man/coo_circularityharalick.Rd Momocs/man/coo_slidedirection.Rd Momocs/man/PCA.Rd Momocs/man/rfourier_shape.Rd Momocs/man/data_oak.Rd Momocs/man/bezier.Rd Momocs/man/scree.Rd Momocs/man/truss.Rd Momocs/man/calibrate_r2.Rd Momocs/man/is.Rd Momocs/man/coo_nb.Rd Momocs/man/coo_samplerr.Rd Momocs/man/m2l.Rd Momocs/man/coo_arrows.Rd Momocs/man/filter.Rd Momocs/man/edi.Rd Momocs/man/chop.Rd Momocs/man/coo_alignminradius.Rd Momocs/man/plot.LDA.Rd Momocs/man/coo_solidity.Rd Momocs/man/sample_n.Rd Momocs/man/coo_eccentricityboundingbox.Rd Momocs/man/l2a.Rd Momocs/man/coo_listpanel.Rd Momocs/man/coo_tangle.Rd Momocs/man/slice.Rd Momocs/man/coo_dxy.Rd Momocs/man/plot3.PCA.Rd Momocs/man/coo_width.Rd Momocs/man/Momocs.Rd Momocs/man/hist.OutCoe.Rd Momocs/man/tie_jpg_txt.Rd Momocs/man/coo_force2close.Rd Momocs/man/rw_rule.Rd Momocs/man/efourier_shape.Rd Momocs/man/pProcrustes.Rd Momocs/man/calibrate_reconstructions.Rd Momocs/man/colors_transp.Rd Momocs/man/rm_asym.Rd Momocs/man/data_bot.Rd Momocs/man/m2ll.Rd Momocs/man/ed.Rd Momocs/man/pos.shapes.Rd Momocs/man/coo_draw.Rd Momocs/man/bind_db.Rd Momocs/man/Coo.Rd Momocs/man/coo_scale.Rd Momocs/man/coo_theta3.Rd Momocs/man/tps_raw.Rd Momocs/man/m2a.Rd Momocs/man/coo_rectangularity.Rd Momocs/man/edm_nearest.Rd Momocs/man/coo_elongation.Rd Momocs/man/import_Conte.Rd Momocs/man/LDA.Rd Momocs/man/coo_smoothcurve.Rd Momocs/man/subset.Rd Momocs/man/coo_bookstein.Rd Momocs/man/coo_circularity.Rd Momocs/man/coo_scalexy.Rd Momocs/man/select.Rd Momocs/man/coo_length.Rd Momocs/man/is_closed.Rd Momocs/man/ntsrow2Coo.Rd Momocs/man/coo_close.Rd

Questions? Problems? Suggestions? or email at

All documentation is copyright its authors; we didn't write any of that.