PyDendro

The PyDendro project provides a set of open source tools for manipulating and analysing dendrochronological data.

PyDendro consists of two main parts:

  • A set of Python modules to read and write dendrochronogical data and perform some basic manipulations.
  • A graphical user interface to visualize ring width measurements and perform basic manipulations.

Documentation

Main parts of the documentation:

Authors

PyDendro is written by:

Installation

To install PyDendro...

Examples

Reading RWL files

To load an RWL file containing ring width measurements:

>>> import pydendro.rwl
>>> rwl = pydendro.rwl.read('site1.rwl')

As this point, rwl is a list of Sample objects. Each Sample object has several attributes:

  • name - sample name
  • fyog - first year of growth
  • widths - list of ring width measurements
  • years - list of years
  • nyears - number of years
  • lyog - last year of growth

From here you can use Pythons rich set of datastructures to work with your data. For example, to build a dictionary of the samples keyed by their name:

>>> samples = { x.name: x for x in rwl }

Now you can fun stuff like print the first year of growth of the ‘AAAD01’ tree:

>>> print samples['AAAD01'].fyog

Graphical analysis

PyDendro also comes with a graphical user interface to load ring widths from multiple sources, plot the ring widths and shift them through time, move samples between stacks, and save the results.

To run the UI, you need the PyQt4 and matplotlib Python packages. To start the UI, run the pydendroui script.

Here is a quick screen shot:

PyDendro UI screenshot

Reference

ITRDB

International Tree Ring Database routines

RWL