<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=windows-1255"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
The raster resolution for the rainfall data was 0.25 degrees, or about
27 km. per pixel. So each pixel covers about 750 sq.km. The column with
the precip_sum will be mm/raster cell, or mm over an area of
750,000,000 sq.m. <br>
Does that make more sense?<br>
<br>
On 06/22/2010 03:57 PM, Sandile Gumede wrote:
<blockquote
cite="mid:AANLkTikRBhqVoVhKMQymRsFErhcnQHAvoMjYOssE5X73@mail.gmail.com"
type="cite">It's in mm/hr. <br>
<br>
Are these values normal, to me it seems like big values because they
are ranging from 2000-4500, see below I just copied a few:<br>
<br>
120795|4076||1|4076|4076|0|4076|0|0|0|4076<br>
120796|4080||1|4080|4080|0|4080|0|0|0|4080<br>
120797|4084||1|4084|4084|0|4084|0|0|0|4084<br>
120798|4088||1|4088|4088|0|4088|0|0|0|4088<br>
120799|4092||1|4092|4092|0|4092|0|0|0|4092<br>
120800|4096||1|4096|4096|0|4096|0|0|0|4096<br>
120801|4100||1|4100|4100|0|4100|0|0|0|4100<br>
120802|4104||1|4104|4104|0|4104|0|0|0|4104<br>
120803|4108||1|4108|4108|0|4108|0|0|0|4108<br>
120804|4112||1|4112|4112|0|4112|0|0|0|4112<br>
120805|4116||1|4116|4116|0|4116|0|0|0|4116<br>
120806|4120||1|4120|4120|0|4120|0|0|0|4120<br>
120807|4124||1|4124|4124|0|4124|0|0|0|4124<br>
120808|4128||1|4128|4128|0|4128|0|0|0|4128<br>
120809|4144||1|4144|4144|0|4144|0|0|0|4144<br>
120810|4148||1|4148|4148|0|4148|0|0|0|4148<br>
120811|4152||1|4152|4152|0|4152|0|0|0|4152<br>
120812|4156||1|4156|4156|0|4156|0|0|0|4156<br>
<br>
<br>
<div class="gmail_quote">2010/6/22 Micha Silver <span dir="ltr"><<a
moz-do-not-send="true" href="mailto:micha@arava.co.il" target="_blank">micha@arava.co.il</a>></span><br>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div bgcolor="#ffffff" text="#000000">
<div>On 22/06/2010 13:08, Sandile Gumede wrote:
<blockquote type="cite">Thanks, I finally got the results.<br>
</blockquote>
</div>
That's good to hear.
<div><br>
<blockquote type="cite"><br>
Now the question I would like to ask is that, from these columns I got
the values but which unit are these values are measured? Is it (mm) or ?<br>
</blockquote>
</div>
Well, that depends on the units of the raster. If the raster values are
mm. then each column represents mm per *raster cell*. So if you have a
rainfall raster with values in mm., and resolution of 10 meters, then
the numbers in the columns are mm/100sq.m.<br>
-- <br>
<font color="#888888">Micha</font>
<div>
<div><br>
<br>
<blockquote type="cite"><br>
<div class="gmail_quote">On Sat, Jun 19, 2010 at 9:57 PM, Micha
Silver <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:micha@arava.co.il" target="_blank">micha@arava.co.il</a>></span>
wrote:<br>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div bgcolor="#ffffff" text="#000000">Hello Sandile:<br>
I tried to duplicate your steps and it seems to work for me.<br>
Here's what I did:
<div><br>
<br>
wget <a moz-do-not-send="true"
href="ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tif"
target="_blank">ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tif</a><br>
wget <a moz-do-not-send="true"
href="ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tfw"
target="_blank">ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tfw</a><br>
<br>
</div>
gdalinfo 3B42RT.2010032900.1day.tif<br>
Driver: GTiff/GeoTIFF<br>
Files: 3B42RT.2010032900.1day.tif<br>
3B42RT.2010032900.1day.tfw<br>
Size is 1440, 480<br>
Coordinate System is `'<br>
Origin = (-180.000000000000000,60.000000000000000)<br>
Pixel Size = (0.250000000000000,-0.250000000000000)<br>
....<br>
<br>
---- Note: no projection info above ----<br>
<br>
---- Now I use the -projwin option of gdal_translate to select a small
window <br>
gdal_translate -a_srs EPSG:4326 -projwin 34.0 33.0 36.0 29.0
3B42RT.2010032900.1day.tif rainfall_il.tif<br>
<br>
---- GEOGCS entry now shows 4326 ----<br>
<br>
g.mapset map=ASTER_DEM loc=WGS84 <br>
----- A location setup as EPSG:4326----<br>
<br>
r.in.gdal israel.tif out=rainfall_il<br>
<br>
r.univar rainfall_il<br>
100%<br>
total null and non-null cells: 77760000
<div><br>
total null cells: 0<br>
<br>
Of the non-null cells:<br>
----------------------<br>
</div>
n: 77760000<br>
minimum: 0<br>
maximum: 34<br>
range: 34<br>
mean: 0.364583<br>
mean of absolute values: 0.364583<br>
standard deviation: 3.45241<br>
variance: 11.9192<br>
variation coefficient: 946.948 %<br>
sum: 28350000<br>
<br>
<br>
----- Now using an existing catchment vector map ----<br>
v.rast.stats vect=arava_wsheds rast=rainfall_il colpre=precip<br>
<a moz-do-not-send="true" href="http://v.info" target="_blank">v.info</a>
-c arava_wsheds<br>
Displaying column types/names for database connection of layer 1:<br>
INTEGER|cat<br>
CHARACTER|label<br>
DOUBLE PRECISION|area_km<br>
INTEGER|precip_n<br>
DOUBLE PRECISION|precip_min<br>
DOUBLE PRECISION|precip_max<br>
DOUBLE PRECISION|precip_range<br>
DOUBLE PRECISION|precip_mean<br>
DOUBLE PRECISION|precip_stddev<br>
DOUBLE PRECISION|precip_variance<br>
DOUBLE PRECISION|precip_cf_var<br>
DOUBLE PRECISION|precip_sum<br>
<br>
---- and some values ----<br>
<br>
v.db.select arava_wsheds <br>
cat|label|area_km|precip_n|precip_min|precip_max|precip_range|precip_mean|precip_stddev|precip_variance|precip_cf_var|precip_sum<br>
21|Jordan|1055.231692|2|0|0|0|0|0|0||0<br>
19|Hidan|987.811979|2|0|0|0|0|0|0||0<br>
28|Og|124.122969|||||||||<br>
36|Zarqa|273.606213|||||||||<br>
24|Kidron|122.460114|||||||||<br>
9|Darga|289.012122|||||||||<br>
6|Arugot|236.365116|1|0|0|0|0|0|0||0<br>
26|Mujib|1277.546513|2|0|0|0|0|0|0||0<br>
<br>
---- (Many catchments have 0 or no value because of the small region I
chose. The global data is 1/4 degree resolution and my region is only 2
deg E-W.)----<br>
<br>
HTH...<br>
-- <br>
Micha
<div>
<div><br>
<br>
<br>
On 06/17/2010 12:50 PM, Sandile Gumede wrote:
<blockquote type="cite">Hi<br>
<br>
It is still giving me -NULL value error.<br>
<br>
Do you think maybe its the way I downloaded my rainfall data? This is
the site where I downloaded my data sets<u> <a moz-do-not-send="true"
href="ftp://trmmopen.gsfc.nasa.gov/pub/gis/" target="_blank">ftp://trmmopen.gsfc.nasa.gov/pub/gis/</a>
</u>and this data covers the whole world, the only thing I
did
was to
clip a specific region (using coordinates) that is in South Africa to
do my analysis. I used a bash script to download and project the data,
see below:<br>
<br>
<br>
#!/bin/bash<br>
<br>
wget <a moz-do-not-send="true"
href="ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tif"
target="_blank">ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tif</a><br>
wget <a moz-do-not-send="true"
href="ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tfw"
target="_blank">ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tfw</a><br>
<br>
gdal_translate -of GTiff -co "PROFILE=GeoTIFF" -co "INTERLEAVE=PIXEL"
-co "COMPRESS=LZW" -co "TILED=YES" -a_srs EPSG:4326 -a_ullr 18.2987501
-33.6795831 19.1712501 -34.3487498 3B42RT.2010032900.1day.tif
TRMMLast1day.tif<br>
<br>
<br>
<br>
<br>
<div class="gmail_quote">On Thu, Jun 17, 2010 at 8:41 AM,
Sandile
Gumede <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:akasandile@gmail.com" target="_blank">akasandile@gmail.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi<br>
<br>
It is still giving me -NULL value error.<br>
<br>
Do you think maybe its the way I downloaded my rainfall data? This is
the site where I downloaded my data sets<u> <a moz-do-not-send="true"
href="ftp://trmmopen.gsfc.nasa.gov/pub/gis/" target="_blank">ftp://trmmopen.gsfc.nasa.gov/pub/gis/</a>
</u>and this data covers the whole world, the only thing I
did
was
to clip a specific region (using coordinates) that is in South Africa
to do my analysis. I used a bash script to download and project the
data, see below:<br>
<br>
<br>
#!/bin/bash<br>
<br>
wget <a moz-do-not-send="true"
href="ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tif"
target="_blank">ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tif</a><br>
wget <a moz-do-not-send="true"
href="ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tfw"
target="_blank">ftp://trmmopen.gsfc.nasa.gov/pub/gis/3B42RT.2010032900.1day.tfw</a><br>
<br>
gdal_translate -of GTiff -co "PROFILE=GeoTIFF" -co "INTERLEAVE=PIXEL"
-co "COMPRESS=LZW" -co "TILED=YES" -a_srs EPSG:4326 -a_ullr 18.2987501
-33.6795831 19.1712501 -34.3487498 3B42RT.2010032900.1day.tif
TRMMLast1day.tif<br>
<br>
<br>
<br>
<div class="gmail_quote">
<div>2010/6/15 Micha Silver <span dir="ltr"><<a
moz-do-not-send="true" href="mailto:micha@arava.co.il" target="_blank">micha@arava.co.il</a>></span><br>
</div>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div bgcolor="#ffffff" text="#000000">
<div>On 15/06/2010 14:35, Sandile Gumede wrote:
<div>
<div>
<blockquote type="cite">Hi<br>
If I run g.region rast=rainfall -p, I get:<br>
</blockquote>
</div>
</div>
</div>
<div>
<div>OK, what you've done here is change the current
region to match the
raster "rainfall".<br>
Can you now try: <br>
v.rast.stats -c vect=catchments rast=rainfall pref=precip<br>
<br>
<br>
<blockquote type="cite">
<div>
<div><br>
projection: 3 (Latitude-Longitude)<br>
zone: 0<br>
datum: wgs84<br>
ellipsoid: wgs84<br>
north: 33:40:46.49916S<br>
south: 34:20:55.49928S<br>
west: 18:17:55.50036E<br>
east: 19:10:16.50036E<br>
nsres: 0:00:05.01875<br>
ewres: 0:00:02.18125<br>
rows: 480<br>
cols: 1440<br>
cells: 691200<br>
<br>
and If I run r.univar rainfall, I get the following output:<br>
<br>
100%<br>
total null and non-null cells: 691200<br>
total null cells: 0<br>
<br>
Of the non-null cells:<br>
----------------------<br>
n: 691200<br>
minimum: 0<br>
maximum: 3094<br>
range: 3094<br>
mean: 22.0228<br>
mean of absolute values: 22.0228<br>
standard deviation: 76.1639<br>
variance: 5800.94<br>
variation coefficient: 345.841 %<br>
sum: 15222164<br>
<br>
<br>
<br>
<div class="gmail_quote">On Tue, Jun 15, 2010 at 12:22
PM,
Hamish <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:hamish_b@yahoo.com" target="_blank">hamish_b@yahoo.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>Micha wrote:<br>
> The only unusual thing I notice above is that the resolution
settings<br>
> for the raster are different N-S and E-W. This came from the
original<br>
> tiff (see below) which also has rectangular pixels,<br>
<br>
</div>
that is perfectly normal for a lat/lon map away from the equator.<br>
longitude scales a cos(lat).<br>
<div><br>
<br>
> (the v.rast.stats module creates a temp raster at the *current
region's<br>
> resolution* settings, which might be different from this rainfall<br>
> raster's rectangular resolution...)<br>
<br>
</div>
the results of:<br>
<br>
g.region -p rast=mapname<br>
r.univar mapname<br>
<br>
<br>
could help.<br>
<font color="#888888"><br>
<br>
Hamish<br>
<br>
<br>
<br>
</font></blockquote>
</div>
<br>
<br clear="all">
<br>
-- <br>
Kind Regards<br>
TS Gumede<br>
CSIR, Meraka Institute<br>
072 258 1650<br>
<br>
<br>
</div>
</div>
<div>This mail was received via Mail-SeCure System.<br>
</div>
</blockquote>
<div><br>
<br>
<pre cols="62">--
Micha Silver
<a moz-do-not-send="true" href="http://www.surfaces.co.il/"
target="_blank">http://www.surfaces.co.il/</a>
Arava Development Co. +972-52-3665918
</pre>
</div>
</div>
</div>
</div>
</blockquote>
</div>
<div>
<div><br>
<br clear="all">
<br>
-- <br>
Kind Regards<br>
TS Gumede<br>
CSIR, Meraka Institute<br>
072 258 1650<br>
<br>
</div>
</div>
</blockquote>
</div>
<br>
<br clear="all">
<br>
-- <br>
Kind Regards<br>
TS Gumede<br>
CSIR, Meraka Institute<br>
072 258 1650<br>
<br>
<br>
This mail was received via Mail-SeCure System.<br>
</blockquote>
<br>
<br>
</div>
</div>
<pre cols="72">--
Micha Silver
Arava Development Co. +972-52-3665918
<a moz-do-not-send="true" href="http://surfaces.co.il" target="_blank">http://surfaces.co.il</a>
</pre>
</div>
</blockquote>
</div>
<br>
<br clear="all">
<br>
-- <br>
Kind Regards<br>
TS Gumede<br>
CSIR, Meraka Institute<br>
072 258 1650<br>
<br>
<br>
This mail was received via Mail-SeCure System.<br>
</blockquote>
<br>
<br>
<pre cols="62">--
Micha Silver
<a moz-do-not-send="true" href="http://www.surfaces.co.il/"
target="_blank">http://www.surfaces.co.il/</a>
Arava Development Co. +972-52-3665918
</pre>
</div>
</div>
</div>
</blockquote>
</div>
<br>
<br clear="all">
<br>
-- <br>
Kind Regards<br>
TS Gumede<br>
CSIR, Meraka Institute<br>
072 258 1650<br>
<br>
<br>
This mail was received via Mail-SeCure System.<br>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="72">--
Micha Silver
<a class="moz-txt-link-freetext" href="http://www.surfaces.co.il/">http://www.surfaces.co.il/</a>
Arava Development Co. +972-52-3665918</pre>
</body>
</html>