GIS and Geologic Mapping Day 2 Tools and

  • Slides: 77
Download presentation
GIS and Geologic Mapping Day 2 Tools and methods to get started using GIS

GIS and Geologic Mapping Day 2 Tools and methods to get started using GIS geologic mapping USGS Astrogeology Oct 2008 GIS for Planetary Geologic Mappers 1

Introduction § Goals – Data Models – Projections – Simple Lon, Lat Display –

Introduction § Goals – Data Models – Projections – Simple Lon, Lat Display – Data Registration – Loading Data – Querying and Spatial Statistics Oct 2008 GIS for Planetary Geologic Mappers 2

Some important notes (cont’d) § Though this presentation is geared toward geologic mappers, the

Some important notes (cont’d) § Though this presentation is geared toward geologic mappers, the information is relevant to all GIS users § Screen-shots are likely to differ from individual views § GIS skills are developed through software interaction … be patient and try new things! Tip icon will point out helpful hints throughout the presentation Oct 2008 GIS for Planetary Geologic Mappers 3

GIS Support § ESRI online portal to technical information – http: //support. esri. com

GIS Support § ESRI online portal to technical information – http: //support. esri. com § ESRI Arc. Scripts – http: //arcscripts. esri. com/ § ESRI Educational Services – Instructor-led training – Virtual Campus courses – Web workshops § Books Oct 2008 GIS for Planetary Geologic Mappers 4

GIS Support Nodes § Planet-specific information (e. g. , data, discussion, tutorials) – http:

GIS Support Nodes § Planet-specific information (e. g. , data, discussion, tutorials) – http: //webgis. wr. usgs. gov/ § USGS discussion board (login required) – http: //isis. astrogeology. usgs. gov/ … navigate to “Support” “Planetary GIS Discussions” “Plugging keywords into a internet search engine is a great way to search for GIS-related assistance!” Oct 2008 GIS for Planetary Geologic Mappers 5

Transition § Data models – quick overview Oct 2008 GIS for Planetary Geologic Mappers

Transition § Data models – quick overview Oct 2008 GIS for Planetary Geologic Mappers 6

Geographic Data Models § Vector and Raster - two main families § Representation of

Geographic Data Models § Vector and Raster - two main families § Representation of geographic information: – Raster: location controlled, attribute measured § values are stored in ordered array, so that position in the array defines geographic location – Vector: attribute controlled, location measured § geographic coordinates are stored separately from attributes, connected with Identifiers 3 43 12 3 45 15 40 2 15 24 21 3 5 10 Oct 2008 (v 1, v 2) V 64 GIS for Planetary Geologic Mappers 7

Rasters and Vectors Vector-based line Raster-based line Flat File 4753456 4753436 4753462 4753432 4753405

Rasters and Vectors Vector-based line Raster-based line Flat File 4753456 4753436 4753462 4753432 4753405 4753401 4753462 4753398 623412 623424 623478 623482 623429 623508 623555 623634 Flat File 00000000 0001100000 101010000 110010000101000010001000 0000100001000000100000001 0111001000011100000000 Oct 2008 GIS for Planetary Geologic Mappers 8

Rasters § Each cell can be owned by only one feature. § Rasters are

Rasters § Each cell can be owned by only one feature. § Rasters are easy to understand, easy to read and write, and easy to draw on the screen. A grid or raster maps directly onto an array. § Grids are poor at representing points, lines and areas, but good at surfaces. § Grids are a natural representation for scanned or remotely sensed data. § Grids suffer from the mixed pixel problem. Oct 2008 GIS for Planetary Geologic Mappers 9

The mixed pixel problem Oct 2008 GIS for Planetary Geologic Mappers 10

The mixed pixel problem Oct 2008 GIS for Planetary Geologic Mappers 10

Methods of Grid Encoding § point-based – center point (regular grid) -DEMs, - but

Methods of Grid Encoding § point-based – center point (regular grid) -DEMs, - but what if periodicity in landscape? ; what if pop. density? – systematic unaligned (random in a cell) § area-based – – – Oct 2008 (have to integrate info. . . ) extreme value (max or min) total (sum, like reflected light) predominant type (most common) presence/absence (binary result) percent cover (% covered by single category) precedence of types (highest ranking) GIS for Planetary Geologic Mappers 11

Discrete (categorical) Legend Mixed conifer Douglas fir Oak savannah Grassland Raster representation. Each color

Discrete (categorical) Legend Mixed conifer Douglas fir Oak savannah Grassland Raster representation. Each color represents a different value of a nominalscale field denoting land cover class. Oct 2008 GIS for Planetary Geologic Mappers 12

§ Next Projections Oct 2008 GIS for Planetary Geologic Mappers 13

§ Next Projections Oct 2008 GIS for Planetary Geologic Mappers 13

Map projections § Define the spatial relationship between locations on earth and their relative

Map projections § Define the spatial relationship between locations on earth and their relative locations on a flat map § Are mathematical expressions § Cause the distortion of one or more map properties (scale, distance, direction, shape) Oct 2008 GIS for Planetary Geologic Mappers 14

Map projections A map projection is a set of rules for transforming features from

Map projections A map projection is a set of rules for transforming features from the three-dimensional earth onto a two-dimensional display. No flat representation of the earth can be completely accurate, so many different projections have been developed, each suited to a particular purpose. Map projections differ in the way they handle four properties: Area, Angles, Distance and Direction. Rules: 1. No projection can preserve all four simultaneously, although some combinations can be preserved, such as Area and Direction 2. No projection can preserve both Area and Angles, however. The map-maker must decide which property is most important and choose a projection based on that. Oct 2008 GIS for Planetary Geologic Mappers 15

Map projections Oct 2008 GIS for Planetary Geologic Mappers 16

Map projections Oct 2008 GIS for Planetary Geologic Mappers 16

Different Plane Locations and Viewpoints Normal or Polar Oct 2008 Oblique GIS for Planetary

Different Plane Locations and Viewpoints Normal or Polar Oct 2008 Oblique GIS for Planetary Geologic Mappers Transverse or Equatorial 17

Different families of projections azimuthal Oct 2008 cylindrical GIS for Planetary Geologic Mappers conic

Different families of projections azimuthal Oct 2008 cylindrical GIS for Planetary Geologic Mappers conic 18

Classification of map projections § Conformal – local shapes are preserved § Equal-Area –

Classification of map projections § Conformal – local shapes are preserved § Equal-Area – areas are preserved § Equidistant – distance from a single location to all other locations are preserved § Azimuthal – directions from a single location to all other locations are preserved Oct 2008 GIS for Planetary Geologic Mappers 19

Standard projections § Standard projections in planetary – Simple Cylindrical (Equidistance Cylindrical, Equirectangular) §

Standard projections § Standard projections in planetary – Simple Cylindrical (Equidistance Cylindrical, Equirectangular) § rectangular global (decimal degrees or meters), simple “database” projection. – Sinusoidal § Used for global and many tiled data releases, equal area projection. – Mercator § Conformal, only use for equatorial areas, used in the Mars 1: 5 M series. – Transverse Mercator § Good for local areas “large” scale maps. A Small scale map shows more land area, but with smaller representations and, therefore, lesser detail. Oct 2008 GIS for Planetary Geologic Mappers 20

Standard projections – cont’d § Standard projections in planetary – Polar Stereographic § Good

Standard projections – cont’d § Standard projections in planetary – Polar Stereographic § Good for polar, error increases away from central latitude (usually 90 or -90). Scale should be based on polar radius, can use polar radius. – Lambert Conformal § Good for mid latitudes. Error increases away from both standard parallels. – Orthographic § Globe view, not good for mapping as the limb falls away, makes for pretty figures but you need 3 globes to portray an entire planet. ISIS uses a spherical equation – Mollweide § Coming of age projection, global Oct 2008 GIS for Planetary Geologic Mappers 21

Standard projections – cont’d § Other projections in planetary – Lambert Azimuthal § Good

Standard projections – cont’d § Other projections in planetary – Lambert Azimuthal § Good for mid latitude and polar, equal area, VICAR/HRSC team uses it for polar areas. – Robinson § Good for figures (similar to Mollweide) Oct 2008 GIS for Planetary Geologic Mappers 22

Geographic – Geocentric Issues § Planetographic vs Planetocentric - issues – Mars is basically

Geographic – Geocentric Issues § Planetographic vs Planetocentric - issues – Mars is basically the only problem – Most commercial commonly don’t use ocentric Arc. Map can. – Work around … use sphere definition for Mars. – For commercial applications, don’t use elliptical definitions and ocentric latitudes. Using elliptical and ographic is okay. Oct 2008 GIS for Planetary Geologic Mappers 23

East-West Longitude § Positive East vs. Positive West – Not much to say because

East-West Longitude § Positive East vs. Positive West – Not much to say because commercial GIS/RS systems use positive East. You should always save your files using positive East. – To use West, you either fake out the system (by using your own code) or you switch software. It is just a shift, so no errors are incurred. – Luckily, if you are working in meters there is no East/West system, only Cartesian (X, Y). Oct 2008 GIS for Planetary Geologic Mappers 24

Setting Projections in Arc § Use toolbox under Arc. Catalog to set dataset’s projection

Setting Projections in Arc § Use toolbox under Arc. Catalog to set dataset’s projection – Toolbox: – Arc. Catalog (data properties) To set many files, under toolbox samples – use batch define projection Oct 2008 GIS for Planetary Geologic Mappers 25

Setting Projections in Arc § Setting planetary bodies in Arc. Map – Example for

Setting Projections in Arc § Setting planetary bodies in Arc. Map – Example for decimal degree (lat/lon) – Okay to set ”Mars 2000. prj” ellipse. (find under “Coordinate SystemsGeographic Coordinate SystemsSolar SystemMars 2000. prj”) (semi-major radius 3396190 m) Oct 2008 GIS for Planetary Geologic Mappers 26

Setting Projections in Arc – Example for the Arc. Map dataframe or for MOLA

Setting Projections in Arc – Example for the Arc. Map dataframe or for MOLA and most raster datasets on the data DVD. – To define a new projection click on New, “Projected” Oct 2008 GIS for Planetary Geologic Mappers 27

Setting Projections in Arc § Mars Polar projection – Note the “D_Mars_2000_Sphere_Polar ” definition

Setting Projections in Arc § Mars Polar projection – Note the “D_Mars_2000_Sphere_Polar ” definition (semi-minor radius 3376200. 0 m ) Oct 2008 GIS for Planetary Geologic Mappers 28

Setting Projections in Arc § Projecting datasets using toolbox Projecting vector Projecting raster datasets

Setting Projections in Arc § Projecting datasets using toolbox Projecting vector Projecting raster datasets Oct 2008 GIS for Planetary Geologic Mappers 29

§ Hands-on (lon/lat display and data frame projections) Oct 2008 GIS for Planetary Geologic

§ Hands-on (lon/lat display and data frame projections) Oct 2008 GIS for Planetary Geologic Mappers 30

Display Lon, Lat Table § Create comma delimited text file (MSL. csv) Name, Lat,

Display Lon, Lat Table § Create comma delimited text file (MSL. csv) Name, Lat, Lon Eberswalde, -23. 86, 326. 73 Holden, -26. 37, 325. 10 Gale, -4. 49, 137. 42 Mawrth, 24. 65, 340. 09 Nili Fossae, 21. 01, 74. 45 Oct 2008 GIS for Planetary Geologic Mappers 31

Load Table 1. 2. Oct 2008 GIS for Planetary Geologic Mappers 32

Load Table 1. 2. Oct 2008 GIS for Planetary Geologic Mappers 32

Display X, Y Data (lat, lon) Right click table 3. 1. 2. Oct 2008

Display X, Y Data (lat, lon) Right click table 3. 1. 2. Oct 2008 GIS for Planetary Geologic Mappers 4. 33

Save to Permanent Right click points Oct 2008 GIS for Planetary Geologic Mappers 34

Save to Permanent Right click points Oct 2008 GIS for Planetary Geologic Mappers 34

Landing Site Error “Ellipse” Open Toolbox Oct 2008 Add Data if needed GIS for

Landing Site Error “Ellipse” Open Toolbox Oct 2008 Add Data if needed GIS for Planetary Geologic Mappers 35

Transition § Simple Image Registration Oct 2008 GIS for Planetary Geologic Mappers 36

Transition § Simple Image Registration Oct 2008 GIS for Planetary Geologic Mappers 36

Worldfile § Most simple image registration 5. 0 0. 0 -5. 0 492169. 690

Worldfile § Most simple image registration 5. 0 0. 0 -5. 0 492169. 690 54523. 3180 (size of pixel in x direction) – A (rotation term for row) - D (rotation term for column) - B (size of pixel in y direction) - E (x coordinate of center of upper left pixel in map units) - C (y coordinate of center of upper left pixel in map units) - F * Oct 2008 GIS for Planetary Geologic Mappers 37

Worldfile § Algebraic Form (six parameter affine transformation) x’ = Ax + By +

Worldfile § Algebraic Form (six parameter affine transformation) x’ = Ax + By + C y’ = Dx + Ey + F where x’ = calculated x-coordinate of the pixel on the map y’ = calculated y-coordinate of the pixel on the map x = column number of a pixel in the image y = row number of a pixel in the image A = x-scale; dimension of a pixel in map units in x direction B, D = rotation terms (assumed to be zero) C, F = translation terms; x, y map coordinates of the center of the upper-left pixel E = negative of y-scale; dimension of a pixel in map units in y direction Oct 2008 GIS for Planetary Geologic Mappers 38

PDS Worldfile § PDS uses same – but X, Y are in “pixel” space

PDS Worldfile § PDS uses same – but X, Y are in “pixel” space OBJECT ^DATA_SET_MAP_PROJECTION_TYPE A_AXIS_RADIUS B_AXIS_RADIUS C_AXIS_RADIUS FIRST_STANDARD_PARALLEL SECOND_STANDARD_PARALLEL POSITIVE_LONGITUDE_DIRECTION CENTER_LATITUDE CENTER_LONGITUDE REFERENCE_LATITUDE REFERENCE_LONGITUDE LINE_FIRST_PIXEL LINE_LAST_PIXEL SAMPLE_FIRST_PIXEL SAMPLE_LAST_PIXEL MAP_PROJECTION_ROTATION MAP_RESOLUTION MAP_SCALE MAXIMUM_LATITUDE MINIMUM_LATITUDE WESTERNMOST_LONGITUDE EASTERNMOST_LONGITUDE LINE_PROJECTION_OFFSET SAMPLE_PROJECTION_OFFSET COORDINATE_SYSTEM_TYPE COORDINATE_SYSTEM_NAME END_OBJECT Oct 2008 = = = = = = = = IMAGE_MAP_PROJECTION "DSMAP. CAT" "SIMPLE CYLINDRICAL" 3396. 0 <KM> "N/A" "EAST" 0. 0 <DEGREE> 180. 0 <DEGREE> "N/A" 1 720 1 1440 0. 0 4. 0 <PIXEL/DEGREE> 14. 818 <KM/PIXEL> 90. 0 <DEGREE> -90. 0 <DEGREE> 360. 5 720. 5 "BODY-FIXED ROTATING" "PLANETOCENTRIC" IMAGE_MAP_PROJECTION Worldfile (MOLA 4 ppd megt 90 n 000 cb. lbl) 14818. 0 (meters) 0. 0 -14818. 0 -10676369. 0 X = SAMPLE_PROJ_OFFSET * MAP_SCALE * -1 5341889. 0 Y = LINE_PROJ_OFFSET * MAP_SCALE http: //pds-geosciences. wustl. edu/missions/mgs/megdr. html GIS for Planetary Geologic Mappers 39

Transition § Loading PDS and ISIS 2, 3 Images Oct 2008 GIS for Planetary

Transition § Loading PDS and ISIS 2, 3 Images Oct 2008 GIS for Planetary Geologic Mappers 40

How to use low-level PDS § Low-level PDS image is basically “raw” – no

How to use low-level PDS § Low-level PDS image is basically “raw” – no map projection – you should not bring it into a GIS – Okay how do you map project raw PDS image § ISIS - Integrated Software for Imagers and Spectrometers – Suse Linux, Solaris UNIX, Mac OSX http: //isis. astrogeology. usgs. gov/ § VICAR - Video Image Communication And Retrieval http: //www-mipl. jpl. nasa. gov/ also maintained at DLR Oct 2008 GIS for Planetary Geologic Mappers 41

How to use low-level PDS http: //isis. astrogeology. usgs. gov/Isis. Support/viewtopic. php? t=423 Why:

How to use low-level PDS http: //isis. astrogeology. usgs. gov/Isis. Support/viewtopic. php? t=423 Why: In short, these programs radiometrically correct the image (level 1) and then geometrically project it through the MOLA DEM to the surface via the spacecraft pointing parameters (SPICE). Again, this is the only way to accurately position the images to the surface for Arc. Map or other GIS/RS software. So without “orthorectification” you should not use as a GIS base. Once a level 2 ISIS image is generated, you can use the included ISIS tools or standalone PERL scripts to make them Arc. Map compatible as described here: http: //isis. astrogeology. usgs. gov/Isis. Support/viewtopic. php? t=357 or http: //isis. astrogeology. usgs. gov/Isis. Support/viewtopic. php? t=358 The ERDAS raw format works well in Arc. Map for multi-band 32 bit images like THEMIS. However, when possible it is still a good idea to convert to 8 bit. Oct 2008 GIS for Planetary Geologic Mappers 42

Using High-level PDS files PERL script to add GIS header: > pds 2 world.

Using High-level PDS files PERL script to add GIS header: > pds 2 world. pl -e -prj pdsimage. img Outputs ERDAS raw header. The “-prj” flag supports creation of a Projection file. for image with detached PDS labels > pds 2 world. pl -e -prj pdsimage. lbl Outputs ERDAS raw header. The “-prj” flag supports creation of a Projection file. http: //webgis. wr. usgs. gov/pigwad/tutorials/scripts/perl. htm Oct 2008 GIS for Planetary Geologic Mappers 43

Using High-level PDS files More on pds 2 world. pl (pds 2 world. exe

Using High-level PDS files More on pds 2 world. pl (pds 2 world. exe also available for Windows) Command line: pds 2 world. pl [-bit=8|16] [-r|-g|-t|-c|-j|-p] [-prj] input. img -r = output raw header and worldfile -e = output ERDAS raw header and worldfile (8, 16, 32 bit) -g = output gif worldfile -t = output tif worldfile -j = output jpeg worldfile -J = output jpeg 2000 worldfile -P = output png worldfile -p = output PCI Aux header (8, 16, 32 bit) -c = output img header and worldfile (default) -prj = create ESRI Well Known Text projection file *. prj Examples: Create files for 32 bit ERDAS: pds 2 world. pl -e input. img ---- (good for ERDAS and Arc. Map) Create files for 32 bit ERDAS: pds 2 world. pl -p input. img ---- (good for GDAL and GDAL conversion) Create worldfile for tif: pds 2 world. pl -t input. img ---- (needs another application to convert pds to Tiff) Oct 2008 GIS for Planetary Geologic Mappers 44

How to use high-level ISIS 2 http: //isis. astrogeology. usgs. gov/Isis. Support/viewtopic. php? t=357

How to use high-level ISIS 2 http: //isis. astrogeology. usgs. gov/Isis. Support/viewtopic. php? t=357 Does ISIS 2 have any routines to convert to an GIS compatible format? There exist ISIS PERL scripts that one can run on the ISIS files to extract this information into header and worldfiles. These ISIS scripts are: dform. pl Convert an ISIS image from 32 or 16 bit to an 8 bit GIS raw, tiff, gif, jpeg with detached GIS files. dform will automatically try to choose a stretch pair for conversion to 8 bit. The user can also specify the stretch pair. isis 2 gisworld. pl Creates GIS headers and GIS worldfiles for ISIS images so that they can be read into most GIS packages. If you are using Arc. Map or ERDAS and wish to maintain a 32 bit file use the ERDAS raw switch " -e ". Examples: Converting to an 8 bit Tiff with GIS headers: > dform. pl -t -bit=8 -gis=yes isis 2 image. cub You will end up with two files - the Tiff image, and a Tiff worldfile. Converting to an 8 bit Jpeg with GIS headers: > dform. pl -j=75 -bit=8 - gis=yes isis 2 image. cub "-j=75" is the Jpeg compression quality (100 is the best). Here, you will end up with two files - the Jpeg image, and a Jpeg worldfile. Creating GIS headers for a 32 bit ISIS cub: > isis 2 gisworld. pl -e isis 2 image. cub You will end up with three files - the ISIS image, a header file "*. raw", and a worldfile "*. rww". This is called an ERDAS raw format. In your GIS you will need to set the NULL ISIS value (more below). Oct 2008 GIS for Planetary Geologic Mappers 45

High-level ISIS 2 files w/o ISIS 2 PERL script to add GIS header: >

High-level ISIS 2 files w/o ISIS 2 PERL script to add GIS header: > isis 2 world. pl -e –prj isis 2 image. cub Outputs ERDAS raw header. The “-prj” flag supports creation of a Projection file. http: //webgis. wr. usgs. gov/pigwad/tutorials/scripts/perl. htm Converting a 16, 32 bit ISIS cub to an ESRI ASCII format: > isis 2 arc myinput. lev 2. cub myoutput. asc Free stand-alone C applicaiton (link) Oct 2008 GIS for Planetary Geologic Mappers 46

Using High-level ISIS 2 files More on isis 2 world. pl (isis 2 world.

Using High-level ISIS 2 files More on isis 2 world. pl (isis 2 world. exe also available for Windows) Command line: isis 2 world. pl [-bit=8|16] [- r|-g|-t|-c|-j|-J|-p|-P|-w ] [-prj] input. cub -r = output raw header w/ georefencing (8, 16 bit) -e = output ERDAS raw header and worldfile (8, 16, 32 bit) -g = output gif worldfile -t = output tif worldfile -w = output generic *. wld worldfile -J = output jpeg 2000 worldfile -j = output jpeg worldfile -P = output a png worldfile -p = output PCI Aux header w/ georefencing (8, 16, 32 bit) -c = output cub header w/ georef (default) (8, 16 bit) -prj = create ESRI Well Known Text projection file *. prj Examples: Create files for 32 bit ERDAS w/ Projection: isis 2 world. pl -e - prj input. cub ----- (good for ERDAS and Arc. Map) Create header for 32 bit PCI Aux: isis 2 world. pl -p input. cub ----- (good for GDAL conversion) Create worldfile for tif: isis 2 world. pl -t input. cub ----- (needs program to convert ISIS file to Tiff) Oct 2008 GIS for Planetary Geologic Mappers 47

How to use high-level ISIS 3 can convert images to GIS compatible format Isis

How to use high-level ISIS 3 can convert images to GIS compatible format Isis 2 std – creates 8 bit only JPEG, PNG (TIFF) with automatic worldfile Examples: Converting to an 8 bit Tiff with GIS headers: > Isis 2 std format=PNG from=myinput. lev 2. cub to=myoutput. png You will end up with two files - the png image, and a png worldfile. http: //isis. astrogeology. usgs. gov/Isis. Support/viewtopic. php? t=357 Oct 2008 GIS for Planetary Geologic Mappers 48

High-level ISIS 3 files w/o ISIS 3 PERL script to add GIS header: >

High-level ISIS 3 files w/o ISIS 3 PERL script to add GIS header: > isis 3 world. pl -e –prj isis 3 image. cub Outputs ERDAS raw header. The “-prj” flag supports creation of a Projection file. http: //webgis. wr. usgs. gov/pigwad/tutorials/scripts/perl. htm Note that ISIS 3 uses a raw “tiled” internal format. This makes supporting this as a generic raw format harder. The ERDAS raw format fortunately supports tiled images. Other formats may require ISIS 3 to output a “BSQ” format instead of a “tiled” format. ISIS 3 example: >crop from=input. cub to=output. cub+bsq Oct 2008 GIS for Planetary Geologic Mappers 49

Using High-level ISIS 3 files More on isis 3 world. pl (isis 3 world.

Using High-level ISIS 3 files More on isis 3 world. pl (isis 3 world. exe also available for Windows) Command line: isis 3 world. pl [-bit=8|16] [- r|-g|-t|-c|-j|-J|-p|-P|-w ] [-prj] input. cub -r = output raw header w/ georefencing (8, 16 bit) -e = output ERDAS raw header and worldfile (8, 16, 32 bit) -g = output gif worldfile -t = output tif worldfile -J = output jpeg 2000 worldfile -j = output jpeg worldfile -P = output a png worldfile -p = output PCI Aux header w/ georefencing (8, 16, 32 bit) -c = output cub header w/ georef (default) (8, 16 bit) -prj = create ESRI Well Known Text projection file *. prj Examples: Create files for 32 bit ERDAS w/ Projection: isis 3 world. pl -e - prj input. cub ----- (good for ERDAS and Arc. Map) Create header for 32 bit PCI Aux: isis 3 world. pl -p input. cub ----- (requires “BSQ” isis 3 file, for GDAL conversion) Create worldfile for tif: isis 3 world. pl -t input. cub ----- (needs program to convert ISIS file to Tiff) Oct 2008 GIS for Planetary Geologic Mappers 50

GDAL for PDS, ISIS 2, ISIS 3 GDAL (binaries available using FWtools and OSGeo

GDAL for PDS, ISIS 2, ISIS 3 GDAL (binaries available using FWtools and OSGeo 4 W): > gdal_translate –of GTIFF isis_ver 3. cub isis_ver 3. tif >gdal_translate -of JP 2 KAK -co "quality=20" ophir_geo. cub ophir_geo. jp 2 Convert from 32, 16 to 8 bit in GDAL >gdalinfo -stats input. cub Take min/max output for scale parameters in gdal >gdal_translate -of GTIFF -ot Byte -a_nodata 0 -scale 0. 21 0. 89 1 255 input. cub output. jp 2 http: //isis. astrogeology. usgs. gov/Isis. Support/viewtopic. php? p=6305 Oct 2008 GIS for Planetary Geologic Mappers 51

Batch Command Line Tip Batch conversion Tips: Unix/Linux code: foreach i (*. cub) foreach>

Batch Command Line Tip Batch conversion Tips: Unix/Linux code: foreach i (*. cub) foreach> =yes $i foreach> perl dform. pl -t -gis=yes foreach> end code: ----------------------------------------foreach i (*. cub) foreach> perl isis 2 gisworld. pl -e $i foreach> end Unix/Linux code: ----------------------------------------foreach i (*. cub) foreach> perl isis 2 world. pl -e $i foreach> end In Ms. DOS command window loop (for Windows machines) code: ----------------------------------------for %i in (*. cub) do isis 2 world -e %i Oct 2008 GIS for Planetary Geologic Mappers 52

Lunch § Next Querying and Spatial Statistics Oct 2008 GIS for Planetary Geologic Mappers

Lunch § Next Querying and Spatial Statistics Oct 2008 GIS for Planetary Geologic Mappers 53

Querying the data § GIS empowers the user to perform spatial searches across any

Querying the data § GIS empowers the user to perform spatial searches across any or all data within a project § A “query” is “a request to select features or records from a database or feature” § The query expression is typically Boolean (based on yes or no answers) § Queries are commonly performed using a dialog box in Arc. Map Oct 2008 GIS for Planetary Geologic Mappers 54

Let’s say that the user wants to find all units that are labeled “plains

Let’s say that the user wants to find all units that are labeled “plains material”. The user will need to query the data as follows. Oct 2008 GIS for Planetary Geologic Mappers 55

Oct 2008 GIS for Planetary Geologic Mappers 56

Oct 2008 GIS for Planetary Geologic Mappers 56

Selecting by feature attributes § Select the layer and field that the query will

Selecting by feature attributes § Select the layer and field that the query will be based on § “Get Unique Values” will give all values in that field § Build the query and click “OK” Oct 2008 GIS for Planetary Geologic Mappers 57

Selecting by feature location § Features can be selected based on relationships with other

Selecting by feature location § Features can be selected based on relationships with other features § Examine the “Select by Location” window for specifics Oct 2008 GIS for Planetary Geologic Mappers 58

Calculating Spatial Statistics § A powerful tool to calculate statistics of a zone dataset

Calculating Spatial Statistics § A powerful tool to calculate statistics of a zone dataset (e. g. , geologic units) based on values from a raster dataset (e. g. , elevation) § Spatial Analyst – Cell statistics – Neighborhood statistics – Zonal statistics § Operates out of Spatial Analyst – Right click empty space on tool bar and select “Spatial Analyst” Oct 2008 GIS for Planetary Geologic Mappers 59

Cell Statistics § “A function that calculates a statistic for each cell of an

Cell Statistics § “A function that calculates a statistic for each cell of an output raster that is based on the values of each cell in the same location of multiple input rasters. ” - paraphrased from ESRI’s online GIS dictionary § For example, the user could find the range and maximum value of albedo from multiple overlapping images acquired in different seasons “Spatial Analyst tools such as cell statistics provide critical analytical components for the interpretation of raster and vector data. Statistics can help improve the quality of geologic maps. ” Oct 2008 GIS for Planetary Geologic Mappers 60

1 2 3 § 1. Add and/or Remove the raster layers that are required

1 2 3 § 1. Add and/or Remove the raster layers that are required for the statistics § 2. Set the statistic that is required (can be minimum, maximum, range, sum, mean, std dev, variety, majority, minority, median) § 3. Type in the output raster name, either as a temporary file (default will be erased the next time the project is closed) or as a TIFF, IMG, or Arc GRID. Oct 2008 GIS for Planetary Geologic Mappers 61

Neighborhood Statistics § A function that calculates a statistic on a raster using a

Neighborhood Statistics § A function that calculates a statistic on a raster using a userspecified “neighborhood”, which implies an extent from individual cells. The extent can be a annulus, circle, rectangle, or wedge. § The user specifies statistics type, neighborhood extent (e. g. , circle with a radius of 4 km), and output cell size (defaultinput cell size) § For example, the user could find the range and maximum value of albedo from multiple overlapping images acquired in different seasons “Using Neighborhood Statistics, a user could create a range of filter types. For example, a median high pass filter can be produced by using a median neighborhood statistic and then subtracting the raster value. ” Oct 2008 GIS for Planetary Geologic Mappers 62

1 2 3 4 § 1. Determine the input dataset and field that will

1 2 3 4 § 1. Determine the input dataset and field that will be the basis of the stats § 2. Set the statistic (minimum, maximum, range, sum, mean, std dev, variety, majority, minority, median) and the neighborhood (annulus, circle, rectangle, wedge) § 3. Set the neighborhood size § Set the output cell size, raster name, and location Oct 2008 GIS for Planetary Geologic Mappers 63

Zonal Statistics § A function that summarizes values in a raster within the zones

Zonal Statistics § A function that summarizes values in a raster within the zones of another layer § The user specifies the “zone dataset” (e. g. , geologic units) the value raster dataset (e. g. , slope) § Output is a Table that summarizes zone statistics § For example, the user could find the range and mean value of slope for geologic units “The Zonal Statistics function allows the user to produce a simplified graph of the statistics. Note the check box in the dialog box. ” Oct 2008 GIS for Planetary Geologic Mappers 64

1 2 3 § 1. Set the Zone dataset (the feature that contains the

1 2 3 § 1. Set the Zone dataset (the feature that contains the region upon which statistics need to be created) § 2. Set the Value raster (the raster dataset that will be the base of the statistics) § 3. Set the statistic that is required (can be minimum, maximum, range, sum, mean, std dev, variety, majority, minority, median) Oct 2008 GIS for Planetary Geologic Mappers 65

Break § Hands on (Spatial Statistics) § Next: Custom Tools Oct 2008 GIS for

Break § Hands on (Spatial Statistics) § Next: Custom Tools Oct 2008 GIS for Planetary Geologic Mappers 66

Customizing Arc. Map 4 Methods for adding functionality to Arc. Map § Install downloaded

Customizing Arc. Map 4 Methods for adding functionality to Arc. Map § Install downloaded programs § Add built in buttons to menus § Create buttons for custom tools § Use Easy Calculate scripts Oct 2008 GIS for Planetary Geologic Mappers 67

Install downloaded programs § Many add-ons available for Arc. Map (e. g. X -Tools,

Install downloaded programs § Many add-ons available for Arc. Map (e. g. X -Tools, Hawth Tools, Arc. Hydro, etc. ) § These install like other programs in the windows environment § After the program is installed, right click on a blank space in the menu and select the toolbar to add § Save the project Oct 2008 GIS for Planetary Geologic Mappers 68

Add buttons for built in functions § Right click on a blank space in

Add buttons for built in functions § Right click on a blank space in the toolbars § Select “Customize” from the drop down menu § Click the “Commands” tab § Search for commands or select a Category § Drag and drop the command to an existing toolbar of your choice § Save the project Oct 2008 GIS for Planetary Geologic Mappers 69

Create buttons for custom tools § Download files from the ESRI website: (http: //support.

Create buttons for custom tools § Download files from the ESRI website: (http: //support. esri. com/index. cfm? fa=downloads. gateway) § Search Arc. Scripts for the tool of interest § Be sure that the tool is built for your version of Arc. GIS § Download the zip file to your computer Oct 2008 GIS for Planetary Geologic Mappers 70

Create buttons for custom tools – cont’d § Decompress the Zip-File to a folder

Create buttons for custom tools – cont’d § Decompress the Zip-File to a folder with a descriptive name § Open the “readme. txt” for instructions § The instructions are different for different file -types § Visual Basic, . DLLs, and Python § Avoid Avenue (Old) and AML (Older) scripts Oct 2008 GIS for Planetary Geologic Mappers 71

Use the Easy Calculate Scripts § Easy Calculate is a set of expressions (currently

Use the Easy Calculate Scripts § Easy Calculate is a set of expressions (currently 110) for the Arc. GIS Field Calculator. § Calculate some spatial characteristics of the features, edit the shapes, add records to a target layer, draw graphics etc. § http: //www. ian-ko. com/free_arcgis. htm Oct 2008 GIS for Planetary Geologic Mappers 72

3 D Visualization § 3 D Analyst Oct 2008 GIS for Planetary Geologic Mappers

3 D Visualization § 3 D Analyst Oct 2008 GIS for Planetary Geologic Mappers 73

Worldfile § Most simple image registration 5. 0 0. 0 -5. 0 492169. 690

Worldfile § Most simple image registration 5. 0 0. 0 -5. 0 492169. 690 54523. 3180 (size of pixel in x direction) – A (rotation term for row) - D (rotation term for column) - B (size of pixel in y direction) - E (x coordinate of center of upper left pixel in map units) - C (y coordinate of center of upper left pixel in map units) - F * Oct 2008 GIS for Planetary Geologic Mappers 74

Worldfile § Algebraic Form (six parameter affine transformation) x’ = Ax + By +

Worldfile § Algebraic Form (six parameter affine transformation) x’ = Ax + By + C y’ = Dx + Ey + F where x’ = calculated x-coordinate of the pixel on the map y’ = calculated y-coordinate of the pixel on the map x = column number of a pixel in the image y = row number of a pixel in the image A = x-scale; dimension of a pixel in map units in x direction B, D = rotation terms (assumed to be zero) C, F = translation terms; x, y map coordinates of the center of the upper-left pixel E = negative of y-scale; dimension of a pixel in map units in y direction Oct 2008 GIS for Planetary Geologic Mappers 75

PDS Worldfile § PDS uses same – but X, Y are in “pixel” space

PDS Worldfile § PDS uses same – but X, Y are in “pixel” space OBJECT ^DATA_SET_MAP_PROJECTION_TYPE A_AXIS_RADIUS B_AXIS_RADIUS C_AXIS_RADIUS FIRST_STANDARD_PARALLEL SECOND_STANDARD_PARALLEL POSITIVE_LONGITUDE_DIRECTION CENTER_LATITUDE CENTER_LONGITUDE REFERENCE_LATITUDE REFERENCE_LONGITUDE LINE_FIRST_PIXEL LINE_LAST_PIXEL SAMPLE_FIRST_PIXEL SAMPLE_LAST_PIXEL MAP_PROJECTION_ROTATION MAP_RESOLUTION MAP_SCALE MAXIMUM_LATITUDE MINIMUM_LATITUDE WESTERNMOST_LONGITUDE EASTERNMOST_LONGITUDE LINE_PROJECTION_OFFSET SAMPLE_PROJECTION_OFFSET COORDINATE_SYSTEM_TYPE COORDINATE_SYSTEM_NAME END_OBJECT Oct 2008 = = = = = = = = IMAGE_MAP_PROJECTION "DSMAP. CAT" "SIMPLE CYLINDRICAL" 3396. 0 <KM> "N/A" "EAST" 0. 0 <DEGREE> 180. 0 <DEGREE> "N/A" 1 720 1 1440 0. 0 4. 0 <PIXEL/DEGREE> 14. 818 <KM/PIXEL> 90. 0 <DEGREE> -90. 0 <DEGREE> 360. 5 720. 5 "BODY-FIXED ROTATING" "PLANETOCENTRIC" IMAGE_MAP_PROJECTION Worldfile (MOLA 4 ppd megt 90 n 000 cb. lbl) 14818. 0 (meters) 0. 0 -14818. 0 -10676369. 0 X = SAMPLE_PROJ_OFFSET * MAP_SCALE * -1 5341889. 0 Y = LINE_PROJ_OFFSET * MAP_SCALE http: //pds-geosciences. wustl. edu/missions/mgs/megdr. html GIS for Planetary Geologic Mappers 76

Questions? Oct 2008 GIS for Planetary Geologic Mappers 77

Questions? Oct 2008 GIS for Planetary Geologic Mappers 77