## Loading the SanMartino precipitation data
data(SanMartinoPPts)
x <- SanMartinoPPts
## Daily to Monthly
m <- daily2monthly(x, FUN=sum, na.rm=TRUE)
## Daily to Annual
daily2annual(x, FUN=sum, na.rm=TRUE)
## Monthly to Annual
monthly2annual(m, FUN=sum, na.rm=TRUE)
############
## Loading the monthly time series of precipitation within the Ebro River basin.
data(EbroPPtsMonthly)
# computing the annual values for the first 10 gauging station in 'EbroPPtsMonthly'
a <- monthly2annual(EbroPPtsMonthly[,1:11], FUN=sum, dates=1)
Run the code above in your browser using DataLab