s.in.ascii
GRASS Reference Manual
s.in.ascii NAME s.in.ascii - Converts an ASCII listing of site locations and their descriptions into a GRASS site list file. (GRASS Sites Program) SYNOPSIS s.in.ascii s.in.ascii help s.in.ascii sites=name [input=name] [fs=character|space|tab] DESCRIPTION s.in.ascii converts an ASCII listing of site locations and category labels into a file in GRASS site list file format. 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. Parameters: sites=name Name of the new GRASS site list file to be output. input=name Name of an existing ASCII file containing site locations and labels. fs=character|space|tab The field separator separating the easting, northing, and category label in each line of the input file. The field separator can be a character, a space, or a tab. Default: space 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: GRASS 5.0beta6 GRASS Development Team 1 s.in.ascii
GRASS Reference Manual
s.in.ascii s.in.ascii sites=name [input=name] [fs=character|space|tab] 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. NOTES Other GRASS programs can be used to produce output in a format suitable for input to s.in.ascii. For example, the user might pipe output produced by d.where into s.in.ascii to create a site list file called my.sites containing site locations pointed to with the mouse, as illustrated below. In this example it was unnecessary to specify the field separator used in the input, since d.where output separates the easting and northing values with spaces, and spaces are the default field separator assumed by s.in.ascii. d.where | s.in.ascii sites=my.sites SEE ALSO d.points, d.sites, d.what.rast, d.where, s.out.ascii, and parser AUTHOR Michael Shapiro, U.S. Construction Engineering Research Laboratory 2 GRASS Development Team GRASS 5.0beta6