Contents:
|
The image finally obtained in this Lesson 4 ![]() |
After starting GRASS, click the lower right button of "Projection values" in the GRASS window
LOCATION: latlon2 MAPSET: PERMANENT DATABASE: /home/student After filling the above information, "Esc" + "Enter"
Please specify the coordinate system for location <utm> A x,y B Latitude-Longitude C UTM D Other Projection RETURN to cancel >B (after typing, "Enter")
Do you wish to specify a geodetic datum for this location? (y/n) [y] y Please specify datum name Enter 'list' for the list of available datums or 'custom' if you wish to enter custom parameters Hit RETURN to cancel request >list (Many datum are displayed) Short Name Long Name / Description (skip) tokyo Tokyo (bessl ellipsoid) wgs72 WGS_1972 (wgs72 ellipsoid) wgs84 WGS_1984 (wgs84 ellipsoid) Please specify datum name Enter 'list' for the list of available datums or 'custom' if you wish to enter custom parameters Hit RETURN to cancel request >wgs84 Now select Datum Transformation Parameters Please think carefully about the area covered by your data and the accuracy you require before making your selection. Enter 'list' to see the list of available Parameter sets Enter the corresponding number, or <RETURN> to cancel request >list Number Details --- 1 Used in whole wgs84 region (PROJ.4 Params towgs84=0.000,0.000,0.000) Default 3-Parameter Transformation (May not be optimum for older datums; use this only if no more appropriate options are available.) --- (skip) >1 DEFINE THE DEFAULT REGION ====== DEFAULT REGION ====== | NORTH EDGE: 15 | | | WEST EDGE | |EAST EDGE 102 | |108 | SOUTH EDGE: 10 | ============================ PROJECTION: 3 (Latitude-Longitude) ZONE: 0 GRID RESOLUTION East-West: 0.00429 North-South: 0.00429 After filling the above information, "Esc" + "Enter"
-> A window of GRASS will show up.
[files in /home/student/data/modis] |
|
Notice: You can move the files either by using Explorer on Windows or by typing a command (mv) on Cygwin
Here, use Enhanced Vegetation Index (EVI) and Normalized Difference Water Index (NDWI) images in the latitude-longitude coordinate derived from MODIS images
> cd /home/student/latlon2/PERMANENT
> r.in.gdal input=2003-2004evi_cambodia.tif output=evi > r.in.gdal input=2003-2004ndwi_cambodia.tif output=ndwi
> d.mon x0 > d.rast evi.red > r.colors map=evi.red rules=evi (reading color table for EVI image) > d.rast evi.red
> r.in.gdal input=2003-2004evi_cambodia.tif output=evi > r.in.gdal input=2003-2004ndwi_cambodia.tif output=ndwi
> g.region w=102 e=108 n=15 s=10 res=0.00429
> r.mapcalc "water1=if(evi.red==0, 0, ndwi.red>=evi.red, 1)" ・ ・ ・ > r.mapcalc "water46=if(evi.46==0, 0, ndwi.46>=evi.46, 1)"
> r.stats -c input=water1 ・ ・ ・ > r.stats -c input=water46 (Example of output "r.stats -c input=water1") 0 1231368 ← [0]: other, [131368]: Total number of "other" pixels 1 16206 ← [1]: water, [16206]: Total number of "water" pixels * 383660
> d.mon x0 > d.rast water?? ← minimun "water area" image > d.mon x1 > d.rast water??? ← maximun "water area" image