t.rast.neighbors.html 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. <h2>DESCRIPTION</h2>
  2. <em>t.rast.neighbors</em> performs <a href="r.neighbors.html">r.neighbors</a>
  3. computations on the maps of a space time raster dataset (STRDS). This
  4. module supports a subset of options that are available in
  5. <a href="r.neighbors.html">r.neighbors</a>. The size of the neighborhood
  6. and the aggregation method can be chosen.
  7. <p>
  8. The user must provide an input and an output space time raster dataset and
  9. the basename of the resulting raster maps. The resulting STRDS will have
  10. the same temporal resolution as the input dataset.
  11. All maps will be processed using the current region settings.
  12. <p>
  13. The user can select a subset of the input space time raster dataset for
  14. processing using a SQL WHERE statement. The number of CPU's to be used
  15. for parallel processing can be specified with the <em>nprocs</em>
  16. option to speedup the computation on multi-core system.
  17. <h2>EXAMPLE</h2>
  18. To smooth the maps contained in a space time dataset run:
  19. <div class="code"><pre>
  20. t.rast.neighbors input=tempmean_monthly output=smooth_tempmean_monthly \
  21. basename=tmean_smooth size=5 method=average nprocs=4
  22. # show some info about the new space time dataset
  23. t.info smooth_tempmean_monthly
  24. +-------------------- Space Time Raster Dataset -----------------------------+
  25. | |
  26. +-------------------- Basic information -------------------------------------+
  27. | Id: ........................ smooth_tempmean_monthly@climate_2000_2012
  28. | Name: ...................... smooth_tempmean_monthly
  29. | Mapset: .................... climate_2000_2012
  30. | Creator: ................... lucadelu
  31. | Temporal type: ............. absolute
  32. | Creation time: ............. 2014-11-27 11:41:36.444579
  33. | Modification time:.......... 2014-11-27 11:41:39.978232
  34. | Semantic type:.............. mean
  35. +-------------------- Absolute time -----------------------------------------+
  36. | Start time:................. 2009-01-01 00:00:00
  37. | End time:................... 2013-01-01 00:00:00
  38. | Granularity:................ 1 month
  39. | Temporal type of maps:...... interval
  40. +-------------------- Spatial extent ----------------------------------------+
  41. | North:...................... 320000.0
  42. | South:...................... 10000.0
  43. | East:.. .................... 935000.0
  44. | West:....................... 120000.0
  45. | Top:........................ 0.0
  46. | Bottom:..................... 0.0
  47. +-------------------- Metadata information ----------------------------------+
  48. | Raster register table:...... raster_map_register_ea1c9a83524e41a784d72744b08c6107
  49. | North-South resolution min:. 500.0
  50. | North-South resolution max:. 500.0
  51. | East-west resolution min:... 500.0
  52. | East-west resolution max:... 500.0
  53. | Minimum value min:.......... -6.428905
  54. | Minimum value max:.......... 18.867296
  55. | Maximum value min:.......... 4.247691
  56. | Maximum value max:.......... 28.767953
  57. | Aggregation type:........... None
  58. | Number of registered maps:.. 48
  59. |
  60. | Title:
  61. | Monthly precipitation
  62. | Description:
  63. | Dataset with monthly precipitation
  64. | Command history:
  65. | # 2014-11-27 11:41:36
  66. | t.rast.neighbors input="tempmean_monthly"
  67. | output="smooth_tempmean_monthly" basename="tmean_smooth" size="5"
  68. | method="average" nprocs="4"
  69. |
  70. +----------------------------------------------------------------------------+
  71. # now compare the values between the original and the smoothed dataset
  72. t.rast.list input=smooth_tempmean_monthly columns=name,start_time,min,max
  73. name|start_time|min|max
  74. tmean_smooth_1|2009-01-01 00:00:00|-3.361714|7.409861
  75. tmean_smooth_2|2009-02-01 00:00:00|-1.820261|7.986794
  76. tmean_smooth_3|2009-03-01 00:00:00|2.912971|11.799684
  77. ...
  78. tmean_smooth_46|2012-10-01 00:00:00|9.38767|18.709297
  79. tmean_smooth_47|2012-11-01 00:00:00|1.785653|10.911189
  80. tmean_smooth_48|2012-12-01 00:00:00|1.784212|11.983857
  81. t.rast.list input=tempmean_monthly columns=name,start_time,min,max
  82. name|start_time|min|max
  83. 2009_01_tempmean|2009-01-01 00:00:00|-3.380823|7.426054
  84. 2009_02_tempmean|2009-02-01 00:00:00|-1.820261|8.006386
  85. 2009_03_tempmean|2009-03-01 00:00:00|2.656992|11.819274
  86. ...
  87. 2012_10_tempmean|2012-10-01 00:00:00|9.070884|18.709297
  88. 2012_11_tempmean|2012-11-01 00:00:00|1.785653|10.911189
  89. 2012_12_tempmean|2012-12-01 00:00:00|1.761019|11.983857
  90. </pre></div>
  91. <h2>SEE ALSO</h2>
  92. <em>
  93. <a href="r.neighbors.html">r.neighbors</a>,
  94. <a href="t.rast.aggregate.ds.html">t.rast.aggregate.ds</a>,
  95. <a href="t.rast.extract.html">t.rast.extract</a>,
  96. <a href="t.info.html">t.info</a>,
  97. <a href="g.region.html">g.region</a>,
  98. <a href="r.mask.html">r.mask</a>
  99. </em>
  100. <h2>AUTHOR</h2>
  101. S&ouml;ren Gebbert, Th&uuml;nen Institute of Climate-Smart Agriculture
  102. <p><i>Last changed: $Date$</i>