GrassASCIIFile: Difference between revisions

From GRASS-Wiki
Jump to navigation Jump to search
(Grass ASCII Format)
mNo edit summary
 
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
I am working with GRASS as a newbie to qualify everything past I.
I am working with GRASS as a newbie to qualify everything past I.


When importing an ASCII file with some arbitrary delimitation, what is the format?
When importing an ASCII file with some arbitrary delimitation, what is the format? I am able to modify my FORTRAN to give me what ever but my search for the format is null.
<nowiki> X        , Y        , Z
 
X        , Y        , Z
----
 
Lat        ,Long      ,Elev
Lat        ,Long      ,Elev
----
DDDMMSSssss,DDDMMSSssss, Meters ---> Which one?
DDDMMSSssss,DDDMMSSssss, Meters ---> Which one?
DDDdddddddd,DDDdddddddd, Meters -|</nowiki>
----
 
DDDdddddddd,DDDdddddddd, Meters -|
 
 
 
----
--HB: ''this question is perhaps better directed at the GRASS user mailing list, not in the wiki, but could be renamed and edited into a nice FAQ entry.''
 
But, to answer your question, these are documented in the [http://grass.osgeo.org/grass63/manuals/html63_user/v.in.ascii.html v.in.ascii help page]. See also the [http://freegis.org/cgi-bin/viewcvs.cgi/~checkout~/grass6/doc/vector/vector.html#ascii GRASS Vector ASCII format specification] for dealing with with features like lines, areas, etc.
 
* The GRASS import tools can typically take any deliminator you specify, the default is "|".
 
--''quote''--
 
<tt> The field separator may be a character, the word 'tab' (or '\t') for tab, or 'space' (or ' ') for a blank.
</tt>
 
--''end-quote''--
 
* Degree-minute-second and hemisphere can be given as +/-DDD.DDDD, DDDh, DDD:MM.MMMMMh, or DDD:MM:SS.SSSSh format.
 
--''quote''--
 
<tt>Latitude/Longitude data may be given in a number of ways. Decimal degrees must be positive or negative instead of using a hemisphere letter. Mixed coordinates must use a hemisphere letter. Whole minutes and seconds must always contain two digits (example: use 167:03:04.567; and not 167:3:4.567).
 
Acceptable formats:
key: D=Degrees; M=Minutes; S=Seconds; h=Hemisphere (N,S,E,W)
 
* (+/-)DDD.DDDDD
* DDDh
* DDD:MMh
* DDD:MM.MMMMMh
* DDD:MM:SSh
* DDD:MM:SS.SSSSSh
</tt>
 
--''end-quote''--
 
 
[[Category:FAQ]]
[[Category: Import]]

Latest revision as of 15:01, 20 December 2012

I am working with GRASS as a newbie to qualify everything past I.

When importing an ASCII file with some arbitrary delimitation, what is the format? I am able to modify my FORTRAN to give me what ever but my search for the format is null.

X         , Y         , Z

Lat ,Long ,Elev


DDDMMSSssss,DDDMMSSssss, Meters ---> Which one?


DDDdddddddd,DDDdddddddd, Meters -|



--HB: this question is perhaps better directed at the GRASS user mailing list, not in the wiki, but could be renamed and edited into a nice FAQ entry.

But, to answer your question, these are documented in the v.in.ascii help page. See also the GRASS Vector ASCII format specification for dealing with with features like lines, areas, etc.

  • The GRASS import tools can typically take any deliminator you specify, the default is "|".

--quote--

The field separator may be a character, the word 'tab' (or '\t') for tab, or 'space' (or ' ') for a blank.

--end-quote--

  • Degree-minute-second and hemisphere can be given as +/-DDD.DDDD, DDDh, DDD:MM.MMMMMh, or DDD:MM:SS.SSSSh format.

--quote--

Latitude/Longitude data may be given in a number of ways. Decimal degrees must be positive or negative instead of using a hemisphere letter. Mixed coordinates must use a hemisphere letter. Whole minutes and seconds must always contain two digits (example: use 167:03:04.567; and not 167:3:4.567).

Acceptable formats: key: D=Degrees; M=Minutes; S=Seconds; h=Hemisphere (N,S,E,W)

  • (+/-)DDD.DDDDD
  • DDDh
  • DDD:MMh
  • DDD:MM.MMMMMh
  • DDD:MM:SSh
  • DDD:MM:SS.SSSSSh

--end-quote--