123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189 |
- <h2>DESCRIPTION</h2>
- <em>t.shift</em> is designed to temporally shift all registered maps in a space time dataset
- with a user defined granularity. Raster, 3D raster and vector space time datasets are supported.
- <p>
- The format of the absolute time granularity is "number unit". Number is an integer, unit is the temporal
- unit that can be one of year(s), month(s), week(s), day(s), hour(s), minute(s) or second(s).
- <p>
- The granularity in case of relative time is an integer. The temporal unit is the unit of the space time dataset
- and can not be modified.
- <h2>Note</h2>
- Be careful when shifting space time datasets with absolute time.
- The temporal granularity may change if you shift a space time dataset with a unit that is
- different from the space time dataset granularity. Be aware that the shifting with months and years
- may result in incorrect days per month. Shifting the date 20012-03-31 with a granularity
- of one month will result in 2012-04-31 which is incorrect. In this case an error will raise
- and the shifting will not performed for the whole dataset.
- <p>
- You can use the extraction module to shift only a subset of maps from a space time dataset.
- Be aware that the shifting of maps affect all space time datasets in which they are registered.
- <h2>EXAMPLE</h2>
- We create 6 raster maps and register them in a space time raster dataset using an increment of one day.
- Then we shift the time intervals with a granularity of 12 hours.
- <div class="code"><pre>
- r.mapcalc expr="prec_1 = rand(0, 550)"
- r.mapcalc expr="prec_2 = rand(0, 450)"
- r.mapcalc expr="prec_3 = rand(0, 320)"
- r.mapcalc expr="prec_4 = rand(0, 510)"
- r.mapcalc expr="prec_5 = rand(0, 300)"
- r.mapcalc expr="prec_6 = rand(0, 650)"
- t.create type=strds temporaltype=absolute \
- output=precipitation_daily \
- title="Daily precipitation" \
- description="Test dataset with daily precipitation"
- t.register -i type=rast input=precipitation_daily \
- maps=prec_1,prec_2,prec_3,prec_4,prec_5,prec_6 \
- start=2012-01-01 increment="1 day"
- t.info type=strds input=precipitation_daily
- +-------------------- Space Time Raster Dataset -----------------------------+
- | |
- +-------------------- Basic information -------------------------------------+
- | Id: ........................ precipitation_daily@soeren
- | Name: ...................... precipitation_daily
- | Mapset: .................... soeren
- | Creator: ................... soeren
- | Creation time: ............. 2013-04-20 14:41:55.392394
- | Temporal type: ............. absolute
- | Semantic type:.............. mean
- +-------------------- Absolute time -----------------------------------------+
- | Start time:................. 2012-01-01 00:00:00
- | End time:................... 2012-01-07 00:00:00
- | Granularity:................ 1 day
- | Temporal type of maps:...... interval
- +-------------------- Spatial extent ----------------------------------------+
- | North:...................... 80.0
- | South:...................... 0.0
- | East:.. .................... 120.0
- | West:....................... 0.0
- | Top:........................ 0.0
- | Bottom:..................... 0.0
- +-------------------- Metadata information ----------------------------------+
- | Number of registered maps:.. 6
- | Title:
- | Daily precipitation
- | Description:
- | Test dataset with daily precipitation
- | Commands of creation:
- | - 2013-04-20 14:41:55 -
- | t.create type="strds" temporaltype="absolute"
- | output="precipitation_daily" title="Daily precipitation"
- | description="Test dataset with daily precipitation"
- | - 2013-04-20 14:41:55 -
- | t.register -i type="rast"
- | input="precipitation_daily"
- | maps="prec_1,prec_2,prec_3,prec_4,prec_5,prec_6" start="2012-01-01"
- | increment="1 day"
- |
- | North-South resolution min:. 10.0
- | North-South resolution max:. 10.0
- | East-west resolution min:... 10.0
- | East-west resolution max:... 10.0
- | Minimum value min:.......... 0.0
- | Minimum value max:.......... 0.0
- | Maximum value min:.......... 296.0
- | Maximum value max:.......... 648.0
- | Raster register table:...... precipitation_daily_soeren_raster_register
- +----------------------------------------------------------------------------+
-
- t.rast.list input=precipitation_daily
- prec_1 soeren 2012-01-01 00:00:00 2012-01-02 00:00:00
- prec_2 soeren 2012-01-02 00:00:00 2012-01-03 00:00:00
- prec_3 soeren 2012-01-03 00:00:00 2012-01-04 00:00:00
- prec_4 soeren 2012-01-04 00:00:00 2012-01-05 00:00:00
- prec_5 soeren 2012-01-05 00:00:00 2012-01-06 00:00:00
- prec_6 soeren 2012-01-06 00:00:00 2012-01-07 00:00:00
- t.shift type=strds input=precipitation_daily granularity="12 hours"
- t.info type=strds input=precipitation_daily
- +-------------------- Space Time Raster Dataset -----------------------------+
- | |
- +-------------------- Basic information -------------------------------------+
- | Id: ........................ precipitation_daily@soeren
- | Name: ...................... precipitation_daily
- | Mapset: .................... soeren
- | Creator: ................... soeren
- | Creation time: ............. 2013-04-20 14:41:55.392394
- | Temporal type: ............. absolute
- | Semantic type:.............. mean
- +-------------------- Absolute time -----------------------------------------+
- | Start time:................. 2012-01-01 12:00:00
- | End time:................... 2012-01-07 12:00:00
- | Granularity:................ 24 hours
- | Temporal type of maps:...... interval
- +-------------------- Spatial extent ----------------------------------------+
- | North:...................... 80.0
- | South:...................... 0.0
- | East:.. .................... 120.0
- | West:....................... 0.0
- | Top:........................ 0.0
- | Bottom:..................... 0.0
- +-------------------- Metadata information ----------------------------------+
- | Number of registered maps:.. 6
- | Title:
- | Daily precipitation
- | Description:
- | Test dataset with daily precipitation
- | Commands of creation:
- | - 2013-04-20 14:41:55 -
- | t.create type="strds" temporaltype="absolute"
- | output="precipitation_daily" title="Daily precipitation"
- | description="Test dataset with daily precipitation"
- | - 2013-04-20 14:41:55 -
- | t.register -i type="rast"
- | input="precipitation_daily"
- | maps="prec_1,prec_2,prec_3,prec_4,prec_5,prec_6" start="2012-01-01"
- | increment="1 day"
- | - 2013-04-20 14:42:21 -
- | t.shift type="strds" input="precipitation_daily"
- | granularity="12 hours"
- |
- | North-South resolution min:. 10.0
- | North-South resolution max:. 10.0
- | East-west resolution min:... 10.0
- | East-west resolution max:... 10.0
- | Minimum value min:.......... 0.0
- | Minimum value max:.......... 0.0
- | Maximum value min:.......... 296.0
- | Maximum value max:.......... 648.0
- | Raster register table:...... precipitation_daily_soeren_raster_register
- +----------------------------------------------------------------------------+
- t.rast.list input=precipitation_daily
- prec_1 soeren 2012-01-01 12:00:00 2012-01-02 12:00:00
- prec_2 soeren 2012-01-02 12:00:00 2012-01-03 12:00:00
- prec_3 soeren 2012-01-03 12:00:00 2012-01-04 12:00:00
- prec_4 soeren 2012-01-04 12:00:00 2012-01-05 12:00:00
- prec_5 soeren 2012-01-05 12:00:00 2012-01-06 12:00:00
- prec_6 soeren 2012-01-06 12:00:00 2012-01-07 12:00:00
- </pre></div>
- <h2>SEE ALSO</h2>
- <em>
- <a href="t.create.html">t.create</a>,
- <a href="t.register.html">t.register</a>,
- <a href="t.snap.html">t.snap</a>
- </em>
- <h2>AUTHOR</h2>
- Sören Gebbert
- <p><i>Last changed: $Date: 2013-01-22 14:44:08 +0100 (Di, 22. Jan 2013) $</i>
|