t.merge.html 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229
  1. <h2>DESCRIPTION</h2>
  2. This module is designed to register the maps of several input space
  3. time datasets in a single output dataset. The datasets to merge can be
  4. either space time raster, 3D raster or vector datasets and must have
  5. the same temporal type (absolute or relative).
  6. <p>
  7. Existing space time datasets located in the current mapset can be
  8. specified as output as well. The maps from the input space time
  9. datasets will be added to the output.
  10. <p>
  11. Maps from the input space time datasets will be registered only once in
  12. the output space time dataset, hence the same maps can be registered in
  13. different input space time datasets.
  14. <h2>NOTES</h2>
  15. Temporal databases stored in other mapsets can be used as long as they
  16. are in the user's current mapset search path (managed with
  17. <a href="g.mapsets.html">g.mapsets</a>).
  18. <h2>Examples</h2>
  19. In this example we will create two space time raster datasets and
  20. register two unique maps in each of it. Then we merge the two space
  21. time raster datasets together.
  22. <div class="code"><pre>
  23. r.mapcalc expression="map1 = rand(0, 10)" -s
  24. r.mapcalc expression="map2 = rand(10, 20)" -s
  25. t.create type=strds temporaltype=absolute \
  26. output=precipitation_daily_1 \
  27. title="Daily precipitation" \
  28. description="Test dataset with daily precipitation"
  29. t.register -i type=raster input=precipitation_daily_1 \
  30. maps=map1,map2 start=2012-08-20 increment="1 days"
  31. t.info precipitation_daily_1
  32. +-------------------- Space Time Raster Dataset -----------------------------+
  33. | |
  34. +-------------------- Basic information -------------------------------------+
  35. | Id: ........................ precipitation_daily_1@soeren
  36. | Name: ...................... precipitation_daily_1
  37. | Mapset: .................... soeren
  38. | Creator: ................... soeren
  39. | Temporal type: ............. absolute
  40. | Creation time: ............. 2014-11-23 15:26:57.395355
  41. | Modification time:.......... 2014-11-23 15:26:57.860513
  42. | Semantic type:.............. mean
  43. +-------------------- Absolute time -----------------------------------------+
  44. | Start time:................. 2012-08-20 00:00:00
  45. | End time:................... 2012-08-22 00:00:00
  46. | Granularity:................ 1 day
  47. | Temporal type of maps:...... interval
  48. +-------------------- Spatial extent ----------------------------------------+
  49. | North:...................... 80.0
  50. | South:...................... 0.0
  51. | East:.. .................... 120.0
  52. | West:....................... 0.0
  53. | Top:........................ 0.0
  54. | Bottom:..................... 0.0
  55. +-------------------- Metadata information ----------------------------------+
  56. | Raster register table:...... raster_map_register_6e6efe25ee9b40e39eb31421d737439b
  57. | North-South resolution min:. 10.0
  58. | North-South resolution max:. 10.0
  59. | East-west resolution min:... 10.0
  60. | East-west resolution max:... 10.0
  61. | Minimum value min:.......... 0.0
  62. | Minimum value max:.......... 10.0
  63. | Maximum value min:.......... 9.0
  64. | Maximum value max:.......... 19.0
  65. | Aggregation type:........... None
  66. | Number of registered maps:.. 2
  67. |
  68. | Title:
  69. | Daily precipitation
  70. | Description:
  71. | Test dataset with daily precipitation
  72. | Command history:
  73. | # 2014-11-23 15:26:57
  74. | t.create type="strds" temporaltype="absolute"
  75. | output="precipitation_daily_1" title="Daily precipitation"
  76. | description="Test dataset with daily precipitation"
  77. | # 2014-11-23 15:26:57
  78. | t.register -i type="rast"
  79. | input="precipitation_daily_1" maps="map1,map2" start="2012-08-20"
  80. | increment="1 days"
  81. |
  82. +----------------------------------------------------------------------------+
  83. r.mapcalc expression="map3 = rand(20, 30)" -s
  84. r.mapcalc expression="map4 = rand(30, 40)" -s
  85. t.create type=strds temporaltype=absolute \
  86. output=precipitation_daily_2 \
  87. title="Daily precipitation" \
  88. description="Test dataset with daily precipitation"
  89. t.register -i type=raster input=precipitation_daily_2 \
  90. maps=map3,map4 start=2012-08-22 increment="1 days"
  91. t.info precipitation_daily_2
  92. +-------------------- Space Time Raster Dataset -----------------------------+
  93. | |
  94. +-------------------- Basic information -------------------------------------+
  95. | Id: ........................ precipitation_daily_2@soeren
  96. | Name: ...................... precipitation_daily_2
  97. | Mapset: .................... soeren
  98. | Creator: ................... soeren
  99. | Temporal type: ............. absolute
  100. | Creation time: ............. 2014-11-23 15:27:20.165074
  101. | Modification time:.......... 2014-11-23 15:27:20.613543
  102. | Semantic type:.............. mean
  103. +-------------------- Absolute time -----------------------------------------+
  104. | Start time:................. 2012-08-22 00:00:00
  105. | End time:................... 2012-08-24 00:00:00
  106. | Granularity:................ 1 day
  107. | Temporal type of maps:...... interval
  108. +-------------------- Spatial extent ----------------------------------------+
  109. | North:...................... 80.0
  110. | South:...................... 0.0
  111. | East:.. .................... 120.0
  112. | West:....................... 0.0
  113. | Top:........................ 0.0
  114. | Bottom:..................... 0.0
  115. +-------------------- Metadata information ----------------------------------+
  116. | Raster register table:...... raster_map_register_04eaede279b2476a80c2683254232f84
  117. | North-South resolution min:. 10.0
  118. | North-South resolution max:. 10.0
  119. | East-west resolution min:... 10.0
  120. | East-west resolution max:... 10.0
  121. | Minimum value min:.......... 20.0
  122. | Minimum value max:.......... 30.0
  123. | Maximum value min:.......... 29.0
  124. | Maximum value max:.......... 39.0
  125. | Aggregation type:........... None
  126. | Number of registered maps:.. 2
  127. |
  128. | Title:
  129. | Daily precipitation
  130. | Description:
  131. | Test dataset with daily precipitation
  132. | Command history:
  133. | # 2014-11-23 15:27:20
  134. | t.create type="strds" temporaltype="absolute"
  135. | output="precipitation_daily_2" title="Daily precipitation"
  136. | description="Test dataset with daily precipitation"
  137. | # 2014-11-23 15:27:20
  138. | t.register -i type="rast"
  139. | input="precipitation_daily_2" maps="map3,map4" start="2012-08-22"
  140. | increment="1 days"
  141. |
  142. +----------------------------------------------------------------------------+
  143. t.merge input=precipitation_daily_1,precipitation_daily_2 \
  144. output=precipitation_daily_3
  145. t.info precipitation_daily_3
  146. +-------------------- Space Time Raster Dataset -----------------------------+
  147. | |
  148. +-------------------- Basic information -------------------------------------+
  149. | Id: ........................ precipitation_daily_3@soeren
  150. | Name: ...................... precipitation_daily_3
  151. | Mapset: .................... soeren
  152. | Creator: ................... soeren
  153. | Temporal type: ............. absolute
  154. | Creation time: ............. 2014-11-23 15:27:44.069272
  155. | Modification time:.......... 2014-11-23 15:27:44.088930
  156. | Semantic type:.............. mean
  157. +-------------------- Absolute time -----------------------------------------+
  158. | Start time:................. 2012-08-20 00:00:00
  159. | End time:................... 2012-08-24 00:00:00
  160. | Granularity:................ 1 day
  161. | Temporal type of maps:...... interval
  162. +-------------------- Spatial extent ----------------------------------------+
  163. | North:...................... 80.0
  164. | South:...................... 0.0
  165. | East:.. .................... 120.0
  166. | West:....................... 0.0
  167. | Top:........................ 0.0
  168. | Bottom:..................... 0.0
  169. +-------------------- Metadata information ----------------------------------+
  170. | Raster register table:...... raster_map_register_33715c8c849a43fbb9bce02e1f28ff5a
  171. | North-South resolution min:. 10.0
  172. | North-South resolution max:. 10.0
  173. | East-west resolution min:... 10.0
  174. | East-west resolution max:... 10.0
  175. | Minimum value min:.......... 0.0
  176. | Minimum value max:.......... 30.0
  177. | Maximum value min:.......... 9.0
  178. | Maximum value max:.......... 39.0
  179. | Aggregation type:........... None
  180. | Number of registered maps:.. 4
  181. |
  182. | Title:
  183. | Merged space time dataset
  184. | Description:
  185. | Merged space time dataset
  186. | Command history:
  187. | # 2014-11-23 15:27:44
  188. | t.merge
  189. | input="precipitation_daily_1,precipitation_daily_2"
  190. | output="precipitation_daily_3"
  191. |
  192. +----------------------------------------------------------------------------+
  193. </pre></div>
  194. <h2>SEE ALSO</h2>
  195. <em>
  196. <a href="t.create.html">t.create</a>,
  197. <a href="t.support.html">t.support</a>,
  198. <a href="t.register.html">t.register</a>
  199. </em>
  200. <h2>AUTHOR</h2>
  201. S&ouml;ren Gebbert, Th&uuml;nen Institute of Climate-Smart Agriculture
  202. <p><i>Last changed: $Date$</i>