description | Read numerical data from an ascii text file into a common lisp array and vice versa. |
owner | soemraws@xs4all.nl |
last change | Sun, 12 Aug 2012 16:49:44 +0000 (12 18:49 +0200) |
URL | git://repo.or.cz/ascii-data.git |
https://repo.or.cz/ascii-data.git | |
push URL | ssh://repo.or.cz/ascii-data.git |
https://repo.or.cz/ascii-data.git (learn more) | |
bundle info | ascii-data.git downloadable bundles |
content tags |
This package provides functions for reading numerical data from ASCII text files into arrays, and writing numerical data from arrays (up to rank 2) into ASCII text files.
If you compare this to numpy's loadtxt, keep in mind that loadtxt will return data consisting of a single row or single column as an array of rank 1, while it will return multi-row, multi-column data as an array of rank 2. Read-ascii-array will always return an array of rank 2. This seemed to make most sense to me from a programming and ASCII layout point of view.
For behaviour similar to numpy's loadtxt, use read-ascii-vector-or-array, which will reduce the rank for you when possible.
Note that the functions with a * appended (which work on streams) can be used in your own specialized reading functions, such as files that contain text headers, or more complex things including gray streams (such as chipz' decompressing-streams).
Note that this package relies on parse-float, which you can find on
github:
git clone git://github.com/soemraws/parse-float.git
2012-08-12 | Sumant Oemrawsingh | READ-ROW* choked on blank lines. Now it skips them... master | commitcommitdifftreesnapshot (tar.gz zip) |
2012-05-13 | Sumant Oemrawsingh | system name was wrong | commitcommitdifftreesnapshot (tar.gz zip) |
2012-04-05 | Sumant Oemrawsingh | write-ascii-vector-or-array did not work | commitcommitdifftreesnapshot (tar.gz zip) |
2012-04-03 | Sumant Oemrawsingh | Replaced erroneous 'float with 'single-float | commitcommitdifftreesnapshot (tar.gz zip) |
2012-04-02 | Sumant Oemrawsingh | in-package was using the wrong package name | commitcommitdifftreesnapshot (tar.gz zip) |
2012-04-02 | Sumant Oemrawsingh | defpackage defined the wrong name for the package | commitcommitdifftreesnapshot (tar.gz zip) |
2012-03-31 | Sumant Oemrawsingh | Fixed typos | commitcommitdifftreesnapshot (tar.gz zip) |
2012-03-31 | Sumant Oemrawsingh | Added some more info to README | commitcommitdifftreesnapshot (tar.gz zip) |
2012-03-31 | Sumant Oemrawsingh | first commit | commitcommitdifftreesnapshot (tar.gz zip) |
12 years ago | master | logtree |