# NOT RUN {
# Create PE data for 2012 for use in the Brompton test case
require(dynatopmodel)
data("brompton")
# Generate time series at hourly and 15 minute intervals
pe.60 <- approx.pe.ts("2012-01-01", "2012-12-31", dt=1)
pe.15 <- approx.pe.ts("2012-01-01", "2012-12-31", dt=0.25)
# Check annual totals - should be around 900mm
sum(pe.60)*1000
sum(pe.15*0.25)*1000
# Check maximum daily total on the 1st of July
sum(pe.60["2012-07-01"])*1000
sum(pe.15["2012-07-01"]*0.25)*1000
# }
Run the code above in your browser using DataLab