-
Notifications
You must be signed in to change notification settings - Fork 79
/
README.Rmd
217 lines (154 loc) · 8.87 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
---
output:
github_document
always_allow_html: true
---
<!-- badges -->
[![CRAN_Status_Badge](http://www.r-pkg.org/badges/version/summarytools)](https://cran.r-project.org/package=summarytools)
[![](http://cranlogs.r-pkg.org/badges/summarytools)](http://cran.rstudio.com/web/packages/summarytools/index.html)
[![](http://cranlogs.r-pkg.org/badges/grand-total/summarytools)](http://cran.rstudio.com/web/packages/summarytools/index.html)
<span class="badge-paypal"><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=HMN3QJR7UMT7S&item_name=Help+scientists,+data+scientists+and+analysts+around+the+globe¤cy_code=CAD&source=url" title="Donate to this project using Paypal"><img src="https://img.shields.io/badge/PayPal-Donate-blue" alt="PayPal donate button"/></a></span>
```{r knitr-setup, include=FALSE}
library(knitr)
opts_chunk$set(echo = TRUE, results = 'asis', class.output = "small")
library(summarytools)
st_options(plain.ascii = FALSE,
style = "rmarkdown",
footnote = NA,
subtitle.emphasis = FALSE,
dfSummary.silent = TRUE,
dfSummary.style = "grid",
descr.silent = TRUE)
library(kableExtra)
```
![package-design-image3](img/st-banner-fuzzy.png)
# Summarytools 1.0 is out!
**summarytools** is a an [*R*](https://www.r-project.org) 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](https://www.rstudio.com/products/rstudio/) IDE,
[Rmarkdown](https://rmarkdown.rstudio.com/), and
[knitr](https://yihui.org/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](#sponsors).
<a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=HMN3QJR7UMT7S&item_name=Help+scientists,+data+scientists+and+analysts+around+the+globe¤cy_code=CAD&source=url"><img src="img/paypal-blue.svg" width="210" height="40"/></a>
# Package Documentation
The bulk of the technical documentation can now be found in the following
vignettes:
[**Introduction to summarytools**](https://htmlpreview.github.io/?https://github.com/dcomtois/summarytools/blob/master/doc/introduction.html) | [CRAN version](https://cran.r-project.org/package=summarytools/vignettes/introduction.html)
[**Summarytools in R Markdown**](https://htmlpreview.github.io/?https://github.com/dcomtois/summarytools/blob/master/doc/rmarkdown.html) | [CRAN Version](https://cran.r-project.org/packages=summarytools/vignettes/rmarkdown.html)
[**PDF Manual**](https://cran.r-project.org/web/packages/summarytools/summarytools.pdf) (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.
<a href="#required-mac-os">Mac OS X</a>
<a href="#required-debian">Ubuntu / Debian / Mint</a>
<a href="#required--older-ubuntu">Older Ubuntu (14 and 16)</a>
<a href="#required-fedora">Fedora / Red Hat / CentOS</a>
<a href="#required-solaris">Solaris</a>
### 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](https://github.com/hrbrmstr/dtupdate) and
[Drat](https://dirk.eddelbuettel.com/code/drat.html).
```{r, eval=FALSE}
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.
```{r, eval=FALSE}
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
### <a id="required-mac-os"></a>Required Software on Mac OS
[**Magick++**](https://imagemagick.org/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**](https://www.xquartz.org/)
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](https://www.xquartz.org/) and add it to your Applications folder.
<a href="#installing-from-github">Back to installation instructions</a>
### <a id="required-debian"></a>Required Software for Debian / Ubuntu / Linux Mint
[**Magick++**](https://imagemagick.org/Magick++/)
`sudo apt install libmagick++-dev`
<a href="#installing-from-github">Back to installation instructions</a>
### <a id="required-older-ubuntu"></a>Required Software for Older Ubuntu Versions
This applies only if you are using Ubuntu Trusty (14.04) or Xenial (16.04).
[**Magick++**](https://imagemagick.org/Magick++/)
sudo add-apt-repository -y ppa:opencpu/imagemagick
sudo apt-get update
sudo apt-get install -y libmagick++-dev
<a href="#installing-from-github">Back to installation instructions</a>
### <a id="required-fedora"></a>Required Software for Fedora / Red Had / CentOS
[**Magick++**](https://imagemagick.org/Magick++/)
`sudo yum install ImageMagick-c++-devel`
<a href="#installing-from-github">Back to installation instructions</a>
### <a id="required-solaris"></a>Required Software for Solaris
[**Magick++**](https://imagemagick.org/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
<a href="#installing-from-github">Back to installation instructions</a>
# <a id="sponsors"></a>Sponsors
A big thanks to the following people who made donations:
- Ashirwad Barnwal
- David Thomas
- Peter Nilsson
- Ross Dunne
- Igor Rubets
- Joerg Sahlmann
- Roger Hilfiker
**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.
<a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=HMN3QJR7UMT7S&item_name=Help+scientists,+data+scientists+and+analysts+around+the+globe¤cy_code=CAD&source=url"><img src="img/paypal-blue.svg" width="210" height="40"/></a>
The package comes with no guarantees. It is a work in progress and feedback is
always welcome. Please open an [issue on
GitHub](https://github.com/dcomtois/summarytools/issues) if you find a bug or
wish to submit a feature request.
<a href="#top">Back to top</a>