API Reference#

This is the class and function reference of ktch.

ktch.landmark: landmark classes and utility functions#

The katatch.landmark module implements landmark-based morphometrics.

Classes#

landmark.GeneralizedProcrustesAnalysis([...])

Generalized Procrustes Analysis (GPA)

Functions#

landmark.centroid_size(x)

Calculate the centroid size.

landmark.tps_grid_2d_plot(x_reference, x_target)

Plot the thin-plate spline 2D warped grid.

ktch.outline: outline classes and utility functions#

The katatch.outline module implements outline-based morphometrics.

The outline, which are boundary lines or boundary surfaces separating the target object from others, are modeled as closed functions.

Classes#

outline.EllipticFourierAnalysis([...])

Elliptic Fourier Analysis (EFA)

Functions#

outline.spharm(n_degree, coefficients[, ...])

SPHARM

ktch.io: I/O utility functions#

Functions#

io.read_tps(file_path[, as_frame])

Read TPS file.

io.write_tps(file_path, landmarks[, ...])

Write TPS file.

ktch.datasets: datasets utility functions#

Functions#

datasets.load_landmark_mosquito_wings(*[, ...])

Load and return the mosquito wing landmark dataset used in [R879dd463bd6e-Rohlf_and_Slice_1990].

datasets.load_outline_mosquito_wings(*[, ...])

Load and return the mosquito wing outline dataset used in [R069eb2748fa9-Rohlf_and_Archie_1984], however includes only 126 of 127 specimens because of missing in the original NTS file.

datasets.convert_coords_df_to_list(df_coords)

Convert a dataframe of coordinates to a list of numpy arrays.

datasets.convert_coords_df_to_df_sklearn_transform(...)

Convert a dataframe of coordinates to a dataframe of coordinates for sklearn transformers.

Plotting#