Re: General Questions in Raven
Posted: Sat Nov 18, 2017 4:58 pm
Hi Elizabeth
I believe you just need to pull the data from within the hydrograph object returned by hyd.read to pass it to the function. The error you get is recreated when a NULL object is passed to the function. Here is an example using the function from the sample data in RavenR, hopefully you can use that to help you with your own data.
Cheers,
Rob
I believe you just need to pull the data from within the hydrograph object returned by hyd.read to pass it to the function. The error you get is recreated when a NULL object is passed to the function. Here is an example using the function from the sample data in RavenR, hopefully you can use that to help you with your own data.
Code: Select all
library(RavenR)
data(hydrograph.data) # sample dataset
myhyd <- hydrograph.data # same format as hyd.read function
# manually specify the sim and obs data, or use hyd.extract function
sim <- myhyd$hyd$Sub43
obs <- myhyd$hyd$Sub43_obs
# ?hyd.extract
# dd <- hyd.extract(subs="Sub43",myhyd)
annual.peak(sim,obs)
Cheers,
Rob