Nothing
dag <- empty_dag() +
node("age", type="rnorm", mean=50, sd=4) +
node("sex", type="rbernoulli", p=0.5) +
node("bmi", type="gaussian", parents=c("sex", "age"),
betas=c(1.1, 0.4), intercept=12, error=2)
test_that("wrong dag", {
expect_error(sim_from_dag(dag="", n_sim=10))
})
test_that("wrong n_sim", {
expect_error(sim_from_dag(dag=dag, n_sim="10"))
})
test_that("wrong sort_dag", {
expect_error(sim_from_dag(dag=dag, n_sim=10, sort_dag=2))
})
test_that("dag with node_td", {
dag <- dag + node_td("testin", type="time_to_event")
expect_error(sim_from_dag(dag, n_sim=10))
})
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.