Nothing
test_that("Chisq distribution", {
dist <- dist_chisq(9)
expect_equal(format(dist), "x2(9)")
# quantiles
expect_equal(quantile(dist, 0.1), stats::qchisq(0.1, 9))
expect_equal(quantile(dist, 0.5), stats::qchisq(0.5, 9))
# pdf
expect_equal(density(dist, 0), stats::dchisq(0, 9))
expect_equal(density(dist, 3), stats::dchisq(3, 9))
# cdf
expect_equal(cdf(dist, 0), stats::pchisq(0, 9))
expect_equal(cdf(dist, 3), stats::pchisq(3, 9))
# F(Finv(a)) ~= a
expect_equal(cdf(dist, quantile(dist, 0.4246)), 0.4246, tolerance = 1e-3)
# stats
expect_equal(mean(dist), 9)
expect_equal(variance(dist), 2*9)
})
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.