InvMillsRatio <- function(x, lt) { ans <- exp(dnorm(x, log=TRUE) - pnorm(-x, lower.tail=lt, log.p=TRUE)) return(ans) }
Add the following code to your website.
REMOVE THIS Copy to clipboard
For more information on customizing the embed code, read Embedding Snippets.