Description Usage Arguments Details Examples
Shows the cross section geometry and fitted model for a given reach and exposure level
1 2 | show_geometry(WSEw, WSEw_obs, cross_section, method, showLegend = TRUE,
...)
|
WSEw |
true height and width values |
WSEw_obs |
observed height and width values |
cross_section |
data frame with x, b for a given reach |
method |
l, sb, nl, nlsb |
... |
optional parameters for plot() |
The code could use a bit of tweaking, but it more or less does what it's supposed to.
1 2 3 4 5 6 7 8 9 10 11 | library(minpack.lm) # required for NL, NLSB methods
exp_dir <- "./Outputs/Final/p21" # pool 21
r <- 1 # reach 1
cross_sections_avg <- readRDS(file.path(exp_dir, "cross_sections_avg.rds"))
cross_section <- data.frame(x = cross_sections_avg$x[[r]], b = cross_sections_avg$b[[r]] )
rWSEw <- readRDS(file.path(exp_dir, "rWSEw.rds"))
WSEw_obs1 <- observe2(WSEw = rWSEw[[r]], exposure = 0.5)
show_geometry(WSEw = rWSEw[[r]],
WSEw_obs = WSEw_obs1,
cross_section = cross_section,
method = "nlsb", ylim = c(130, 145))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.