plot.tmdl: Plots Load Duration Curve

Description Usage Arguments Value See Also Examples

Description

Plots Load Duration Curve

Usage

1
2
## S3 method for class 'tmdl'
plot(x, ...)

Arguments

x

tmdl object returned by tmdl

...

other parameters for bwplot

Value

Trellis object with LDC

See Also

tmdl, ldplot

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
data(flow)
data(pol)
flow.ranked <- rankflow(flow,pol,names=list(date="Date",Q="cfs"))
WQS <- 5 # mg/L => 10 NTU

# simple WLA definition
kr.tmdl <- tmdl(flow.ranked,names=list(Q="cfs",pol="TSS"),WQS=WQS, WLA=1)
plot(kr.tmdl, plot=list(WLA=TRUE))

# WLA as a list of functions
WLA.construction <- function(exc,LC,MOS,LC.fun,MOS.fun) {
  LA = ifelse(exc>75, LC.fun(75)-MOS.fun(75), LC - MOS)
  .01 * LA
}
MS4.Duluth <- function(exc,LC,MOS,LC.fun,MOS.fun) {
  .16 * (LC-MOS-WLA.construction(exc,LC,MOS,LC.fun,MOS.fun))
}
WLA <- list("WLA (constr.)"=WLA.construction, MS4=MS4.Duluth)
kr.tmdl <- tmdl(flow.ranked,names=list(Q="cfs",pol="TSS"),WQS=WQS, WLA=WLA)
fig <- plot(kr.tmdl, plot=list(MOS=TRUE, WLA=TRUE))
plot(fig)

# apply custom theme
update(fig, par.settings = theEconomist.theme())

tmdl documentation built on May 2, 2019, 6:07 p.m.

Related to plot.tmdl in tmdl...