Description Usage Arguments Details Value Examples
This function identifies if multiple gauges are located in the same grid cell (e.g. GPM pixel) and averages their time-series to obtain a single best ground-based estimate to compare and merge with the satellite data.
1 | combine_gauges(gauge.sp, gauge.ts)
|
gauge.sp |
A SpatialPointsDataFrame object containing the gauge locations and additional gauge attributes. |
gauge.ts |
A zoo object containing the gauge observations. |
This function averages (simple mean) multiple gauges if these are located in the same grid cell (i.e. GPM pixel) such that a single time-series for the ground-based estimate is obtained for every grid node. In order for this function to work, the function colocate
needs to be run previously such that the required GPM pixel identifiers are assigned to each gauge location.
Object gauge.list
A list with two entries: the gauge spatial data identical to that in the object gauge.sp
and a revised time-series object with a single unique time-series corresponding to each GPM grid node that contained gauges.
1 2 3 4 5 6 7 8 9 | data(gpm) # STFDF object with gpm imerg observations
data(gauges) # STFDF object with gauge observations
gauges <- colocate(gauges,gpm,resolution=0.1,longlat=TRUE)
gauge.sp <- gauges@sp
gauge.ts <- as(gauges[,,1],"xts")
colnames(gauge.ts) <- gauge.sp$estacion
gauge.list <- combine_gauges(gauge.sp,gauge.ts)
gauge.sp <- gauge.list$sp
gauge.ts <- gauge.list$ts
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.