Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

One of the most time-consuming part of data analysis in science is the copy-pasting of specific values of some R output to a manuscript or a report. This task is frustrating, prone to errors, and increases the variability of statistical reporting. At the sime time, standardizing practices of what and how to report is crucial for reproducibility and clarity. The new report package was designed specifically to do this job.

# Install report

report is part of the new easystats suite of packages. However, as it is not (yet) on CRAN, you’ll need to install it directly from github.

devtools::install_github("easystats/report")  # Install the latest psycho version

library(report)  # Load the package

# Do a correlation

df <- iris  # Load the traditional iris dataset into an object called df (for dataframe)
cor_results <- cor.test(df$Sepal.Length, df$Petal.Length)  # Compute a correlation and store its result

# Formatted output

The report package include a single function, namely report(), that can be applied to a correlation to format its content.

report(cor_results)
## The Pearson's product-moment correlation between df$Sepal.Length and ## df$Petal.Length is positive, significant and large (r = 0.87, p < .001).

The formatted output includes the direction, effect size (interpreted by default using Cohen’s (1988) rules of thumb) and confidence intervals. Now, you can just copy and paste this line into your report and focus on more important things.

# Evolution

Of course, these reporting standards should change, depending on new expert recommendations or official guidelines. The goal of this package is to flexibly adaptive to new changes and good practices evolution. Therefore, if you have any advices, opinions or such, we encourage you to either let us know by opening an issue, or even better, try to implement them yourself by contributing to the code.