skip to navigation
skip to content

coards 0.2.2

Convert COARDS time specification to a datetime object.

This module converts between a given COARDS time specification and a Python datetime object, which is much more useful. Suppose you have an Array of values [1,2,3] and units "days since 1998-03-01 12:00:00":

>>> a = [1, 2, 3]
>>> units = 'days since 1998-03-01 12:00:00'
>>> b = [from_udunits(value, units) for value in a]
>>> print b[0].year
1998
>>> b[1] > b[0]
True
>>> print b[1] - b[0]
1 day, 0:00:00

The list b now contains objects which can be compared and manipulated in a consistent way.

The latest version is available in a Subversion repository.

File Type Py Version Uploaded on Size # downloads
coards-0.2.2.tar.gz (md5) Source 2007-01-25 15:01:21 4KB 1330
coards-0.2.2-py2.4.egg (md5) Python Egg 2.4 2007-01-25 15:01:22 8KB 539

Log in to rate this package.