Input can be entered via standard input or from the file input=name. Each line of input should contain the easting, northing, and (optionally) the category label associated with a site. The fs=name option (where name is either a character, a space, or a tab) can be used to specify the use of a particular field separator between these three input fields. This is useful when input is obtained from other programs (see NOTES, below). Output is stored in the file sites=name and placed in the site_lists directory under the user's current mapset.
The GRASS program s.out.ascii can be used to perform the reverse function, converting a file in GRASS site list format into an ASCII listing of eastings, northings, and category labels associated with site locations.
s.in.ascii can be run either non-interactively or interactively. The program will be run non-interactively if the user specifies a name to be assigned to the sites file output, the name of an existing ASCII file containing input, and (optionally) a field separator fs appearing in the input file, using the form:
Alternately, the user can simply type s.in.ascii on the command line, without program arguments. In this case, the user will be prompted for parameter values using the standard GRASS parser interface described in the manual entry for parser. If the user does not specify the name of an input file containing site locations and (optionally) category labels, these should be entered to the program via standard input. The parameter d allows to specify that more than 2 dimensions will be imported. Otherwise the third (or further) column in input file is treated as attribute.
#any comment, can be inserted anywhere name|mysoils.site desc|3D soils data for location A time|15 Jan 1999 labels|east north elevation ID pH Corg color form||||#%%@
Data:
Each line of the ascii input file should contain either two or three
coordinates (x,y and optionally z) separated by a user-selectable
field-delimiting character. After the coordinates there are optional
attribute fields separated from the coordinates and from each other with
the same user-selectable field delimiter.
The attribute field may be a category number, a decimal value or a string. Category numbers must be preceded by the "#" character and string values must be preceded by the "@" character. Floating point values may be preceded by the "%" character but if there is no "#" or "@" preceding the attribute then it is assumed to be a floating point value. Also, string values that contain blanks must be quoted or the part of the string following the first blank will be parsed as a separate field, which may cause an error.
easting|northing|[z|[d4|]...][#category_int] [ [@attr_text OR %flt] ... ]
such as:
739865.8|4279785.5|#2965 %396685 %194919 %160392 %10941 %2.473222 @"St.Louis" @MO @city
There can be many dimensions between pipes (|), but no #%@.
There can be only one cat, preceded by #, then there may be many FP or text attributes.
Importing latitude/longitude data
Latitude/longitude data may be imported either in decimal degree format:
8.314824 54.921730 site1 8.897605 54.872353 site2 9.549371 54.834080 site3or in DMS (degree, minutes, seconds) format:
8:18:53.3664E 54:55:18.228N site1 8:53:51.378E 54:52:20.4708N site2 9:32:57.7356E 54:50:02.688N site3
Time as String Attributes
In this example, we will work with the following site list:
10.8 0 9.8 Fri Sep 13 10:00:00 1986 31.4 11 5.5 9.9 Fri Sep 14 00:20:00 1985 36.4 5.1 3.9 10 Fri Sep 15 00:00:30 1984 28.4This data has three dimensions (assume easting, northing, and elevation), five string attributes, and one decimal attributes.
Last changed: $Date: 2002/10/20 08:51:59 $