Extracting Site Data from DLG-3 Files

Scott Tweddale tweddale at gis.uiuc.edu
Wed Nov 10 10:25:54 EST 1993


David Hoover writes:

>He is trying to import data from an ARC-INFO system via a DLG file.
>The DLG has point data in it represented as degenerate lines.  He can
>read the file and see the point data, and the v.in.dlg program recognizes
>the lines and comes back with a message about degenerate lines.  The file
>also contains 1 line that represents a quadrangle boundary.  After
>importing the file to GRASS, he only gets the quadrangle boundary and no
>point data even as degenerate lines.  He know this because when he runs
>v.support, it only shows 1 processed line.  He is running version 4.0.

I am not sure why you are losing your points when using DLG as an intermediate
format, but I have had similar problems in the past when attempting to read
site data in arc and convert directly to GRASS.  David Stigberg of USACERL
wrote a small program which takes arc site data and converts it to degenerate
lines which can then be imported directly to GRASS using v.in.arc.

If you still have the original arc data and you want to give this a try, respond
to me directly and I'll give you the program.   A description of the program 
follows.

usage:    

	   convert.to.line < input.file > output.file

will convert input.file such as the following:

 1    123.234   234.345	
 2    234.234    23.123
 0    123.333. 3333.333
 4   -222.22   333.333

 etc. etc.

to produce the following output file which will work with v.in.arc: 

 1    
 123.234   234.345	
 123.234   234.345	
END
 2    
 234.234    23.123
 234.234    23.123
END
 0    
 123.333. 3333.333
 123.333. 3333.333
END
 4   
 -222.22   333.333
 -222.22   333.333
END
END


put the outfile in $LOCATION/arc, and then run v.in.arc


Scott Tweddale
U. of Illinois GIS Lab Coordinator/USACERL-ENE
tweddale at gis.uiuc.edu



More information about the grass-user mailing list