I would expect the following to return the original network instead of an error:
data(Kenai1)
Kenai1.trim <- trimriver(trim=integer(), rivers=Kenai1)
Error in trimriver(trim = integer(), rivers = Kenai1) :
Error - resulting river network has no remaining line segments
In addition: Warning messages:
1: In max(trim, na.rm = T) :
no non-missing arguments to max; returning -Inf
2: In min(trim, na.rm = T) :
no non-missing arguments to min; returning Inf
Hello, and (many) apologies for missing your messages from >5 years ago!! That's a great catch. I will fix on my branch, I'm assuming that will be easiest.
I would expect the following to return the original network instead of an error: