Skip to content

dcomtois/summarytools

Repository files navigation

CRAN_Status_Badge PayPal donate button

package-design-image3

Summarytools 1.0 is out!

summarytools is a an R package for data cleaning, exploring, and simple reporting. The package was developed with the following objectives in mind:

  • Provide a coherent set of easy-to-use descriptive functions that are akin to those included in commercial statistical software suites such as SAS, SPSS, and Stata
  • Offer flexibility in terms of output format & content
  • Integrate well with commonly used software & tools for reporting (the RStudio IDE, Rmarkdown, and knitr) while also allowing for standalone, simple report generation from any R interface

On a more personal level, I simply wish to share with the R community and the scientific community at large the functions I first developed for myself, that I ultimately realized would benefit a lot of people who are looking for the same thing I was seeking in the first place.

Support summarytools’ Development

If summarytools helps you get things done, please consider making a donation. By doing so now, you’ll help me feel useful, but more importantly contribute to the package’s development and help other people like you who benefit from its current and future features. I regularly receive feature requests, and when I receive donations, I set aside some time to work on them, making summarytools even more relevant for data scientists, students and researchers around the world. No matter how small the amount is, I always appreciate the gesture. A list of sponsors can be found further below.

Package Documentation

The bulk of the technical documentation can now be found in the following vignettes:

Introduction to summarytools | CRAN version
Summarytools in R Markdown | CRAN Version
PDF Manual (automatically generated by CRAN)

Installing summarytools

Required Software

Additional software is used by summarytools for fine-tuning graphics as well as offering interactive functionality. If you are installing summarytools for the first time, click on the relevant link to get OS-specific instructions. On Windows, no additional software is required.

Mac OS X
Ubuntu / Debian / Mint
Older Ubuntu (14 and 16)
Fedora / Red Hat / CentOS
Solaris

Installing From GitHub

This method has the advantage of benefiting from minor fixes and improvements that are added between CRAN releases. Its main drawback is that you won’t be noticed when a new version is available. You can either check this page from time to time, or best, use a package that checks for package updates on various repositories, such as dtupdate and Drat.

install.packages("remotes")        # Using devtools is also possible
library(remotes)
install_github("rapporter/pander") # Strongly recommended
install_github("dcomtois/summarytools", build_vignettes = TRUE)

Installing From CRAN

CRAN versions are stable but are not updated as often as the GitHub versions. On the plus side, they can be easier to install on some systems.

install.packages("summarytools")

Latest Changes

  • In dfSummary():

    • It is now possible to control which statistics to show in the Freqs / Values column (see help("st_options", "summarytools") for examples)
    • In html outputs, tables are better aligned horizontally (categories >> counts >> charts); if misalignment occurs, adjusting graph.magnif should resolve it
    • List-type columns and Inf values are handled properly
  • In descr() and ctable() several display glitches were corrected

  • Selected heading elements can be totally omitted on an individual basis

  • Improved functionality for customized terms / translations

For more details, see vignette("introduction", "summarytools") as well as news(package = "summarytools").

Additional Software Installations

Required Software on Mac OS

Magick++

Open a terminal window and enter the following:

brew install imagemagick@6

If you do not have brew installed, simply enter this command in the terminal:

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

XQuartz

If you’re using Mac OS X version 10.8 (Mountain Lion) or more recent versions, you’ll need to download the .dmg image from xquartz.org and add it to your Applications folder.

Back to installation instructions

Required Software for Debian / Ubuntu / Linux Mint

Magick++
sudo apt install libmagick++-dev

Back to installation instructions

Required Software for Older Ubuntu Versions

This applies only if you are using Ubuntu Trusty (14.04) or Xenial (16.04).

Magick++

sudo add-apt-repository -y ppa:opencpu/imagemagick
sudo apt-get update
sudo apt-get install -y libmagick++-dev

Back to installation instructions

Required Software for Fedora / Red Had / CentOS

Magick++
sudo yum install ImageMagick-c++-devel

Back to installation instructions

Required Software for Solaris

Magick++

pkgadd -d http://get.opencsw.org/now
/opt/csw/bin/pkgutil -U
/opt/csw/bin/pkgutil -y -i imagemagick 
/usr/sbin/pkgchk -L CSWimagemagick

Back to installation instructions

Sponsors

A big thanks to the following people who made donations:

  • Ashirwad Barnwal
  • David Thomas
  • Peter Nilsson
  • Ross Dunne
  • Igor Rubets
  • Joerg Sahlmann

summarytools is the result of many hours of work. If you find the package brings value to your work, please take a moment to make a small donation.

The package comes with no guarantees. It is a work in progress and feedback is always welcome. Please open an issue on GitHub if you find a bug or wish to submit a feature request.

Back to top