Skip to content

Commit

Permalink
Merge pull request #301 from USEPA/add-mc3-method-resp.censormed.neg25
Browse files Browse the repository at this point in the history
add level 3 method resp.censormed.neg25
  • Loading branch information
madison-feshuk authored Nov 5, 2024
2 parents ceacf6a + 882dad2 commit b5043db
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 11 additions & 1 deletion R/mc3_mthds.R
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,8 @@
#' \eqn{resp=cval/bval-1}{resp = cval/bval - 1}. Typically used for increasing responses.}
#' \item{resp.mult100}{Multiply the normalized response value (resp) by 100;
#' \eqn{100*resp}{100*resp}.}
#' `\item{resp.censormed.neg25}{Censor (remove) response values from
#' concentrations which median falls below -25.}
#' }
#' }
#'
Expand Down Expand Up @@ -692,7 +694,15 @@ mc3_mthds <- function() {
e1 <- bquote(dat[J(.(aeids)), pval := -100,
by=list(aeid)])
list(e1)
}
},

resp.censormed.neg25 = function(aeids) {

e1 <- bquote(dat[J(.(aeids)), med := median(resp), by=list(aeid,spid,conc)])
e2 <- bquote(dat <- dat[med >= -25])
e3 <- bquote(dat[ , med := NULL])
list(e1,e2,e3)
}



Expand Down
2 changes: 2 additions & 0 deletions man/MC3_Methods.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit b5043db

Please sign in to comment.