Return to LAS FAQ
How can I get 'batch' access to LAS data, i.e. without going through the user interface?
If a Live Access Server has a lot of useful data, particularly if it is regularly updated, it won't be long before people want to automatically harvest the data. Although we've tried to make the LAS user interface as friendly as possible, interactions with it cannot be automated. To address the need for 'batch' access to LAS data we have written a couple of scripts which can interact with LAS, bypassing the user interface.
W currently provide two scripts:
You can find out how to use the scripts by running them with no arguments:
Usage: ls.pl [-l] [-s separator] url [dataset] [variable]
-l displays descriptive name for a dataset or variable
and the type, units, and bounds of an axis.
-s separator delimit fields with separator
Example: ls.pl http://ferret.pmel.noaa.gov/las-bin/LASserver.pl
Usage: lasget.pl [-x xrange ] [-y yrange] [-z zrange]
[-t trange] [-f format] [-o file]
url dataset variable
-x xrange x range of data (-120, -120:80)
-y yrange y range of data (0, 0:90)
-z zrange z range of data (0, 0:20)
-t trange time range of data (1992-Dec-10, 1992-Jan-1:1992-Dec-1)
-o file output file. Defaults to stdout
-f format output format asc|cdf|txt|ps|html
url URL of LAS server
dataset name of dataset
variable name of variable
Note that these perl scripts require some additional perl modules which may not have been previously installed on your system.
You can pick up these modules by using the Perl CPAN module; type perldoc CPAN for more info.
Jonathan Callahan: Jonathan.S.Callahan@noaa.gov
Last modified: July 24, 2002