theta <- c(rep(0, 100), rexp(100))
theta[1:50] <- 0
s <- 1
x <- theta + rnorm(200, 0, s)
pn.res <- ebnm_point_normal(x, s)
plot(pn.res)
pe.res <- ebnm_point_exponential(x, s)
plot(pn.res, pe.res)
# Customize plot:
library(ggplot2)
plot(pn.res, pe.res, remove_abline = TRUE) +
theme_bw() +
labs(x = "Simulated data")
Run the code above in your browser using DataLab