library(otvPlots)
library(proto)
context("Plot categorical variable")
load("../testthat/testData.rda")
setDT(testData)
test_that("PlotCatVar returns a gtable", {
PrepData(testData, dateNm = "date", dateGp = "weeks", dateGpBp = "months")
p <- PlotCatVar("marital", testData, NULL, "weeks", "months")$p
expect_is(p, "gtable")
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.