ACCESSING AND MANIPULATING DIGITAL LINE GRAPH (DLG) DATA FROM CDROM


/* There are many different sources and many different formats of DLG data.
/* This script was written to access, download, and manage Hydrography and
/* Transportation data from the USGS' 1:100,000-Scale Geodata set on CDROM.
/* Included are "pre-processing" commands and an AML.
/*
/* COMMANDS FOR PRE-PROCESSING DLG DATA
/*
/* The CDROM contains hydro, road, rail, & miscellaneous transportation
/* files for each 1:100,000-scale quadrangle in the geographical region.
/* On the CDROM, under the directory titled 100k_DLG, quadrangle names for
/* the region are plainly abbreviated. Each quadrangle name exists as a
/* subdirectory under 100k_DLG. Zipped DLG files of the four types
/* mentioned above reside within each of the quadrangle subdirectories.
/* Once the user has identified his/her particular area/region/watershed of
/* interest, the corresponding adjacent quadrangle files may be downloaded
/* from CDROM. The following are examples of downloading hydro and road
/* files for the Austin and Sequin, TX quadrangles:
/*
$: cp /cdrom/100k_DLG/austin/au3hydro.zip ./
$: cp /cdrom/100k_DLG/austin/au3roads.zip ./
$: cp /cdrom/100k_DLG/sequin/sg1hydro.zip ./
$: cp /cdrom/100k_DLG/sequin/sg1roads.zip ./
/*
/* Each of the downloaded files then needs to be "unzipped":
/*
$: unzip au3hydro.zip
$: unzip au3roads.zip
$: unzip sg1hydro.zip
$: unzip sg1roads.zip
/*
/* Performing this command "explodes" each quadrangle data set
/* into eight 15-minute map data files (e.g. au3hydro.zip explodes to
/* au3hyf01 through au3hyf08, sg1roads.zip explodes to sg1rdf01 through
/* sg1rdf08). The rest of the process is repetitive and is best handled
/* via AML.
/*
/***************************************************************************
/*
/* AN ARC AML FOR PREPARING DLG DATA FOR REGIONAL ANALYSIS
/* AML NAME: dlgprep.aml (run from the "Arc" prompt)
/* FUNCTION: Prepares selected DLG data for analysis with respect to a
/* particular hydrologic or political region.
/*
/* INPUTS:
/* all "exploded" 15-minute DLG map files from the pre-processing
/* steps above.
/* utmalb.prj - a projection file converting from utm map coordinates to
/* albers (or whatever projection is desired) map coordinates
/* border - a polygon coverage of the hydrologic or political region of
/* interest (must also be in the same projection as the DLGs).
/*
/***************************************************************************
/*
/* BEGIN AML EXECUTION
/*
/* This first set of commands should be performed for each DLG map file
/* created in the pre-processing steps above (e.g. in this case, 32 sets of
/* commands).
/* Each exploded file should be converted from the DLG optional format (as
/* stored on CDROM) to an Arc/Info coverage through use of the dlgarc
/* command.
/*
dlgarc optional au3hyf01 aushyd1
/*
/* Construct topology for each of the new coverages. Use "build"
/* to ensure that rpoly# and lpoly# are created within each of the Arc
/* Attribute Tables (aat's).
/*
build aushyd1 line
/*
/* Each of these coverages is a separate 15' map with a border around its
/* outside edge. In order eliminate the border from appearing in the
/* resultant appended map, the arcs that constitute the border should be
/* removed from the coverage:
/*
reselect aushyd1 auswatr1 line # line
res rpoly# > 1
<return>
N
Y
res lpoly# > 1
<return>
N
N

/*
/* At this point, the additional 31 (or however many) sets of dlgarc,
/* build, and reselect commands should be inserted into the AML. For
/* example:
/*
/* dlgarc optional sg1rdf01 segroad1
/* build segroad1 line
/* reselect segroad1 seghwys1 line # line
/* res rpoly# > 1
/* <return>
/* N
/* Y
/* res lpoly# > 1
/* <return>
/* N
/* N
/*
/* Append all of the resultant hydro maps together:
/*
append hydromap
/*
/* Include all 16 separate hydro maps to be appended:
/*
auswatr1
:
:
auswatr8
segwatr1
:
:
segwatr8
<return>

/*
/* Repeat the process for the road coverages:
/*
append roadmap
aushwys1
:
:
aushwys8
seghwys1
:
:
seghwys8
<return>

/*
/* Project the resultant appended maps into the desired projection:
/*
project cover hydromap areahyd utmalb.prj
project cover roadmap arearoad utmalb.prj

/*
/* Construct topology for each of the projected coverages:
/*
build areahyd line
build arearoad line

/*
/* Isolate the projected coverages to the particular hydrologic or
/* political area of interest. (Make sure that the border coverage is in
/* a common projection):
/*
clip areahyd border hydarcs line
clip arearoad border roadarcs line

/*
/* The coverages hydarcs and roadarcs are now ready for analysis within the
/* region of interest.
/*
/************************End of AML*****************************************
/*


Quick Connect to DLG Web Site
Go to AML Listing