|
How To work with spatial data in the Geospatial Learning Center
Two GIS software packages are available in the Geospatial Learning Center: ArcView 3.3 (also ArcView 9.2 is installed) ArcInfo 9.2 Both software packages are made by ESRI (http://www.esri.com/). The new version of ArcInfo has three new windows-based features, ArcCatalog, ArcMap and ArcToolbox. You can read more about the new features on the ESRI web-page or in the manuals available in the RS/GIS lab. You can run ArcInfo with the command line by selecting ArcInfo Workstation under ArcInfo in the Start menu.
Copying: You can move shape files between directories on your computer by using ‘copy – paste’ in windows or ‘dragging and dropping’ files with the computer mouse. Always remember to also copy the .dbf and the .shx file to the destination directory. This also applies to renaming shape files. If the shape file river.shp is renamed to river2.shp the corresponding .dbf and .shx files MUST also be renamed river2.dbf and river2.shx. Beyond .shx, .shp and .dbf files there are a sometimes other file extensions in ArcView such as .sbn, .sbx, .aih, and .ain. If you notice these files in your directory, for example river.sbn and river.sbx they MUST also stay together with the river.shp file. ALWAYS KEEP ArcView FILES WITH THE SAME PREFIX TOGETHER. You can also use the Manage Data Sources in ArcView to copy, rename and delete ArcView shapefiles. Select File – Manage Data Sources in the main menu to activate this feature. Shape files may display points, lines or polygons. Display: ArcView shape files can be opened as themes in ArcView but can not be displayed in ArcInfo. A shape file can be converted to an ArcInfo coverage using the Arc command shapearc. An ArcInfo coverage can be converted to a shape file using the command arcshape in Arc. View attributes: The attributes to a shape file are contained in the .dbf file. This file can be viewed in ArcView by making the theme active and pressing the Open table icon.
A folder that contains coverages is called a workspace. Copying: You must use the command copy in ArcInfo when you copy ArcInfo coverages from one workspace to another. For example – copy the coverage river from c:\temp to e: Enter the copy command at the Arc prompt: Arc: copy c:\temp\river e:\river
ArcInfo coverages CAN NOT be copied in the windows environment by ‘copy-paste’ or ‘drag and drop’ from one folder to the other. By copying in windows the data in the info directory will be lost and the coverage will be irrecoverably corrupted and lost forever. You may however move the entire workspace using the windows ‘copy-paste’ or ‘drag and drop’. For example the workspace idaho contains the coverages river and landuse. In the workspace idaho there is also an info folder. The entire workspace (folder) idaho may be moved with ‘copy – paste’ or ‘drag and drop’. However the individual coverages river and landuse must be copied using the Arc copy commad. Display: ArcInfo coverages can be displayed in ArcInfo as well as in ArcView. You can also perform queries on ArcInfo coverages in ArcView, however you must save the coverages as a shape file before you can edit the polygons or attribute table. Delete: Delete ArcInfo coverages with the kill command. For example, delete the coverage mycover: Arc: kill mycover all This deletes the coverage mycover and all associated Info files. List: List all ArcInfo coverages in a workspace Arc: lc Change workspace: Go to the workspace c:\temp Arc: w c:\temp
Grids are raster data with a specified pixel size. In order to view grids in ArcView the Spatial Analyst extension must be turned on. When you add a grid theme the Data Source Type must be set to Grid.
In order to view a grid named testgrid in ArcInfo Workstation, use the following series of commands: Arc: grid (takes you into the grid module) Grid: display 9999 (activates the display screen) Grid: mape testgrid (sets map extent) Grid: gridshades testgrid (displays testgrid with the default shadeset)
How to import spatial data to your GIS Whether your spatial data comes from a web site, is transported via an ftp site or found in the lab spatial data library it will most likely come in one of the archive formats described below. Before you can view the data it must be converted to a shape file, coverage, grid, image or tin.
At the Unix prompt type : uncompress rivers.tar.Z
A .dem file is an ASCII file containing information to create an elevation grid (lattice) You can import the dem in ArcView or ArcInfo.
Select the .dem file with the browser and click OK. Select a destination folder and a name for the output grid and click OK. ArcView will import the grid.
Import DEM in ArcInfo Example: Import the dem named deary.dem to a lattice (elevation grid). Name the output grid deary_ele. Arc: demlattice deary.dem deary_ele
How to examine a coverage in ArcView or ArcInfo We have just acquired the polygon coverage landuse and would like to examine the data. ArcView
4. Examine the attribute table of the coverage landuse selecting Table from the Theme drop-down menu or click the ‘Open Table’ GUI.
ArcInfo 1 . Arc: describe landuse
2. Arc: items landuse.pat
3. Arc: list landuse.pat
4. Draw the coverage in Arcplot or Grid Arc: grid (or arcplot) starts the Gird or Arcplot session Grid: display 9999 activates the display window Grid: mape landuse mapextent Grid: polys landuse draw polygons 5. Arc: lc list all the vector coverages in the workspace 6. Arc: lg list all grids in the workspace
How to project a shapefile or coverage In order to display the 3-dimensional surface of the earth on a flat 2-dimensional map the surface must be projected. There are many projections in different coordinate systems. The following three projections are commonly used in Idaho:
Much of the data in /clan/library is in UTM, zone 11, datum nad27.
Project shape files in ArcView 3.2 1. Turn on the Projector extension File – Extensions – select Projector!
2. Open a view and add the theme you would like to project. View – Add theme 3. Set the View properties View-Properties The units of your coverage or shapefile depend on what projection the file is in:
4. Make the theme you want to project the active theme. 5. Press the Projector GUI and follow the instructions. Sometimes the input projection will be read from the input shapefile and sometimes you will have to enter the input projection manually. Read the Projector instructions carefully.
Project coverages and grids in ArcInfo Coverages and grids can be projected in ArcInfo. The syntax is: Arc: project <coverage/grid> <incover> <outcover> The project module will then prompt you to enter a series of projection parameters.
How to make a CD from your ArcView project What is an ArcView project? An ArcView project has the extension .apr and is simply and ASCII text file. The project itself does not contain any of the shapefiles, coverages or grids that can be viewed when you open the project in ArcView. The ArcView project contains a series of lines pointing at shapefiles, coverages and grids in various folders on the computer you are presently working on. This is an example of part of an ArcView project: NOTICE the reference to the g: drive on the first line of the .apr file below!
Prepare a computer folder and ArcView project for a CD application
The 'Find and Replace' feature is located under the Edit dropdown menu in most wordprocessing software.
You need to replace the drive C: from the path because you don’t know what drive the CD reader is going to be on the computer where the studyarea.apr will be read. 6. Save studyarea.apr in Wordpad and exit. Do not open and save studyarea.apr in ArcView after the above find/replace since a save will add the drive C: to the paths in the project again.
Write the CD
If all worked well you should be able to open your ArcView project and view the data on the CD on any computer that has ArcView installed.
|
|