pyNarian: A developing Python library for image processing and geometric morphometric trajectory analysis
Geometric morphometrics is a set of techniques for mathematically describing and analyzing the shape of structures without losing information on the structure’s geometry (Adams et al 2013). Often such methods rely on the coordinates of a set of landmarks to characterize the specimen.
-Image processing, the retrieval of data from two-dimensional images, is a crucial step in many geometric morphometric studies. Yet almost all morphometric studies rely on a handful of programs for image processing. As a result, the routines that are available to researchers are often constrained to those available in these programs.
One of the most common image processing programs used in morphometrics is tpsDig2 (Rolhf 2010). As a result, tpsDig2 has influenced the file formats commonly used in the field; the TPS file format is among the most common formats for storing the coordinates of landmarks.
Geometric morphometrics is a growing discipline with new methods constantly being added. For instance, there has recently been increasing efforts to develop methods to analyze how the shapes of one or more specimens change over some period time, a field that could be termed shape trajectory analysis. These new methods can be statistically and computationally complex to the point of being inaccessible to many researchers. As a result, those developing these methods must often create software capable of implementing them.
Here we introduce the library pyNarian. There are two major groups of routines in pyNarian, those for image processing and those for trajectory analysis. A major design goal for pyNarian is ease of use and extension. Therefore, it is written in the user-friendly language Python. However, it simultaneously can handle complex numerical and graphical operations through its incorporation of the libraries numpy (Oliphant 2007), matplotlib (Hunter 2007), and the Python Image Library (Pythonware 2012).