txt_mcnemar_report | R Documentation |
This function returns html formatted text summary of McNemar's Chi-sqauare test, for paired data. The input object must be a 'mcnemar.test' object, and the p-value is formatted by the 'htmlTable::txtPval()' function.
txt_mcnemar_report(mcnemar_object)
mcnemar_object |
A McNemar's Chi-square object |
txtPval
, sprintf
, mcnemar.test
ex <- data.frame(A = sample(c("No", "Yes"), 9, replace = T),
B = sample(c("No", "Yes"), 9, replace = T))
ex
result <- mcnemar.test(table(ex$A, ex$B))
txt_mcnemar_report(result)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.