Extracts and restructures statistical standard results like Z, t, Cohen's d, F, eta^2, r, R^2, chi^2, BF_10, Q, U, H, OR, RR, beta values into a matrix. Performs a recomputation of two- and one-sided p-values if possible. This function is implemented in get.stats
which returns the results of allStats
and standardStats
. Besides only plain textual input, get.stats
enables direct processing of different file formats (NISO-JATS coded XML, DOCX, HTML) without text preprocessing.
standardStats(
x,
stats.mode = "all",
recalculate.p = TRUE,
alternative = "undirected",
estimateZ = FALSE,
T2t = FALSE,
R2r = FALSE,
select = NULL,
rm.na.col = TRUE,
warnings = TRUE
)
Matrix with recognized statistical standard results and recalculated p-values. Empty, if no result is detected.
result vector by allStats
or chracter vector with a statistical test result per cell, e.g. c("t(12)=1.2, p>.05","chi2(2)=12.7, p<.05")
Select subset of standard stats. One of: c("all", "checkable", "computable", "uncomputable").
Logical. If TRUE recalculates p values (for 2 sided test) if possible.
Character. Select test sidedness for recomputation of p-values from t-, r- and beta-values. One of c("undirected", "directed"). If "directed" is specified, p-values for directed null-hypothesis are added to the table but still require a manual inspection on consistency of the direction.
Logical. If TRUE detected beta-/d-value is divided by reported standard error "SE" to estimate Z-value ("Zest") for observed beta/d and recompute p-value. Note: This is only valid, if Gauss-Marcov assumptions are met and a sufficiently large sample size is used. If a Z- or t-value is detected in a report of a beta-/d-coefficient with SE, no estimation will be performed, although set to TRUE.
Logical. If TRUE capital letter T is treated as t-statistic.
Logical. If TRUE capital letter R is treated as correlation.
Select specific standard statistics only (e.g.: c("t", "F", "Chi2")).
Logical. If TRUE removes all columns with only NA.
Logical. If FALSE warning messages are omitted.
Böschen (2021). "Evaluation of JATSdecoder as an automated text extraction tool for statistical results in scientific reports.” Scientific Reports. doi: 10.1038/s41598-021-98782-3.
study.character
for extracting multiple study characteristics at once.
get.stats
for extracting statistical results from textual input and different file formats.
x<-c("t(38.8)<=>1.96, p<=>.002","F(2,39)<=>4, p<=>.05",
"U(2)=200, p>.25","Z=2.1, F(20.8,22.6)=200, p<.005,
BF(01)>4","chi=3.2, r(34)=-.7, p<.01, R2=76%.")
standardStats(x)
Run the code above in your browser using DataLab