Description Usage Arguments Details Value See Also Examples
This style functions takes a correlation test (htest class) from
cor.test
and transforms it into a formatted character
vector, including p value. Statistics are printed optionally (not by
default).
1 | style.apa.cor.test(x, print.statistic = FALSE)
|
x |
a list. First item must be a correlation test (htest class) from
|
print.statistic |
a logical, indicating whether test statistic is printed as well. Corresponding p value is always printed. |
Please note that this is a internal style function. It is called
from pprint
and not exported to user namespace. Usually
pprint
determines the correct style function automatically,
but you can define the style function by using the format
argument
of pprint
(pass the name of this function without
style.apa.
prefix). Additionally you can pass the arguments listed
in this documentation to pprint
.
Argument x
of this function expects a list. Be aware that you do not
have to pass a list to pprint
or pull.pubprint
– these functions will convert your arguments. This is only necessary if
you want to pass additionally information to the internal style functions
(see vignette for examples).
character vector with a formatted character vector.
Other APA.style.functions: style.apa.anova
,
style.apa.bartlett
,
style.apa.character
,
style.apa.chisq
,
style.apa.df
,
style.apa.fisher
,
style.apa.ks
,
style.apa.numeric
,
style.apa.p.value
,
style.apa.shapiro
,
style.apa.summary.aovlist
,
style.apa.summary.lm.beta.coeff
,
style.apa.summary.lm.coeff
,
style.apa.summary.lm.equation
,
style.apa.summary.lm.model
,
style.apa.t.test
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | a <- rnorm(100)
b <- rnorm(100) * .75 + a * .25
pprint(cor.test(a, b), format = "cor.test")
pprint(cor.test(a, b, method = "kendall"), format = "cor.test")
pprint(cor.test(a, b, method = "spearman"), format = "cor.test")
pprint(cor.test(a, b),
format = "cor.test",
print.statistic = TRUE)
pprint(cor.test(a, b, method = "kendall"),
format = "cor.test",
print.statistic = TRUE)
pprint(cor.test(a, b, method = "spearman"),
format = "cor.test",
print.statistic = TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.