JASP Graphical Statistical Software For Common Sta
JASP Graphical Statistical Software For Common Sta
Eric-Jan Wagenmakers
University of Amsterdam
Abstract
This paper introduces JASP, a free graphical software package for basic statistical pro-
cedures such as t tests, ANOVAs, linear regression models, and analyses of contingency
tables. JASP is open-source and differentiates itself from existing open-source solutions in
two ways. First, JASP provides several innovations in user interface design; specifically,
results are provided immediately as the user makes changes to options, output is attrac-
tive, minimalist, and designed around the principle of progressive disclosure, and analyses
can be peer reviewed without requiring a “syntax”. Second, JASP provides some of the
recent developments in Bayesian hypothesis testing and Bayesian parameter estimation.
The ease with which these relatively complex Bayesian techniques are available in JASP
encourages their broader adoption and furthers a more inclusive statistical reporting prac-
tice. The JASP analyses are implemented in R and a series of R packages.
Keywords: JASP, statistical software, Bayesian inference, graphical user interface, basic statis-
tics.
2 JASP: Graphical Statistical Software for Common Statistical Designs
1. Introduction
The speed of scientific progress greatly benefits from the availability of free and open-source
software. The need for such software is particularly acute in the arena of statistical (re)analysis,
for at least three reasons. First, the availability of the software’s source code enables re-
searchers to probe the adequacy of the underlying algorithms to establish whether or not
a program’s results are trustworthy. Second, open-source software ensures the freedom of
researchers to extend and adjust existing work. Finally, open-source software can be shared
freely, from one researcher to the next, without cost. In contrast, proprietary software is
generally provided without source code for review, without permission to modify it, and with
substantial licensing costs.
Unfortunately, proprietary software continues to be entrenched in the field of statistics, some-
thing which holds true especially for “basic statistics”, that is, statistical methods for widely
used procedures such as t tests, ANOVAs, linear regression, and contingency tables. The
canonical example of a proprietary statistical software package is SPSS (IBM Corporation
2013). The SPSS program has a long history and is popular in education as well as in em-
pirical research. A Google Scholar search for academic articles that contain the term “SPSS”
produces over 100,000 results for the year 2014 alone. Given that SPSS is just one of many
proprietary statistical packages used within science, this suggests that proprietary software
maintains a substantial market share. This suggestion is corroborated by the Reproducibil-
ity Project (Open Science Collaboration 2015), a large-scale project that sought to replicate
100 high-profile psychology studies; out of the 100 replication attempts carried out by differ-
ent psychology groups around the world, as many as 84 used proprietary software for their
data analysis (https://osf.io/ezcuj/wiki/home/).
Thus, the current state of affairs in the field of software for basic statistics is decidedly
suboptimal: Proprietary software remains entrenched, despite the clear and present drawbacks
both for statistical education and for scientific progress. At the same time, it is obvious that
science stands to gain considerably from adopting open-source alternatives, as this (1) enables
peer review of the software; (2) facilitates the development and adoption of new statistical
methods; and (3) reduces costs to the scientific and university communities.
To further the use of open-source statistical software, a number of programs and environments
have been developed, the most high profile of these being the R programming language (R
Core Team 2018). Although R is the program of choice for statisticians and methodologists,
its command line interface and steep learning curve are sometimes believed to be a barrier
to its broader adoption. This concern is most pressing for students and applied researchers,
that is, for people who use statistics only occasionally, and for basic problems (Valero-Mora
and Ledesma 2012). These occasional users do not require the full flexibility that R has to
offer, and their statistical demands can be met by software with a graphical user interface. In
light of this, a number of projects have developed graphical open-source statistical software
for basic statistics. A select list includes PSPP (The GNU Foundation 2015), SOFA (Paton-
Simpson & Associates 2015), RKWard (Rödiger et al. 2012), Deducer (Fellows 2012), and R
Commander (Fox 2005). Continuing in this tradition, we have developed JASP: a graphical,
open-source statistical platform for performing common statistical tasks, designed to be simple
and intuitive to use, and available for Windows, Mac OS X and Linux.
There are two features that set JASP apart from existing software. First, JASP provides a
number of innovations in user interface design. These include providing results to the user
Journal of Statistical Software 3
in real-time as they make changes, providing minimalist, attractive output which is ready
to publish, and allowing the user to see exactly what interface options were used to specify
an analysis, without requiring the use of a “syntax”. Indeed, we believe that JASP’s unique
user interface approach might inspire similar efforts in the future. Second, JASP provides
a series of Bayesian analyses for basic statistical tests, featuring both parameter estimation
and default Bayes factor hypothesis testing (Jeffreys 1961; Kass and Raftery 1995). These
Bayesian analyses echo their classical counterparts, thereby encouraging the exploration of
alternative statistical methodology and a more inclusive style of statistical reporting. To date,
the Bayesian methods have not been made available in graphical statistical software.
The outline of this article is as follows. We first list the analyses available in JASP and
describe the JASP user interface. We then explain JASP’s unique design philosophy and
illustrate the use of JASP with a concrete example. Subsequently we explain how JASP is
implemented.
2. Available analyses
The development of JASP started in 2013 with support from a grant from the European
Research Council. As of version 0.7 (September 2015), JASP provides descriptive statistics
along with the following basic analysis methods:
• ANCOVA.
• Linear regression.
• Tests of correlation.
• Contingency tables.
As mentioned above, JASP not only provides the classical implementation of these tests but
also features their Bayesian equivalents. The Bayesian t tests are based on the work of Jeffreys
(1961, see also Ly et al. 2016; Rouder et al. 2009; Wetzels et al. 2009). The Bayesian ANOVA,
ANCOVA, and linear regression are based on the work of Liang et al. (2008, see also Rouder
and Morey 2012; Rouder et al. 2012; Wetzels et al. 2012). The Bayesian tests of correlation
are based on the work of Jeffreys (1961, see also Ly et al. 2016), and the Bayesian contingency
tables are based on the work of Gunel and Dickey (1974, see also Jamil et al. 2017). For many
applied researchers, these tests represent the workhorses of their discipline. Future releases of
JASP will include additional procedures such as log linear regression and logistic regression.
output that is displayed in the right hand panel. The output of a new analysis is appended
immediately below the outcome of the preceding analysis, a property that will be explored
further in the worked example provided in Section 5.
1. The user specifies the options for the analysis using the user interface.
2. An intermediate syntax is generated from the user interface options.
3. This intermediate syntax is passed to some sort of “statistical engine” to perform the
analysis.
Users wishing to keep a record of the analysis options retain the intermediate syntax from step
2. Those who wish to review the analysis at a later point in time are required to “decode” and
6 JASP: Graphical Statistical Software for Common Statistical Designs
5. JASP example
The following example illustrates the functionality of JASP through a t test example based on
an empirical data set. We use JASP to reanalyze a subset of the data from a recent adversarial
collaboration that focused on the ostensibly beneficial effects of horizontal eye movements on
memory (Matzke et al. 2015). Matzke and colleagues presented participants with a list of
study words for a subsequent free-recall memory test (i.e., a test that requires participants to
recall as many words from a study list, regardless of their order). Immediately following the
study phase, one group of participants was requested to fix their gaze on a dot in the middle of
the screen, whereas the other group was requested to perform a short series of horizontal eye
movements. The hypothesis under scrutiny holds that the number of correctly recalled words
is higher in the horizontal condition than in the fixation condition; consequently Matzke and
colleagues tested this hypothesis with a one-sided independent samples Bayesian t test (e.g.,
Wetzels et al. 2009). The complete data set is available on the Open Science Framework
at http://openscienceframework.org/project/pXT3M/. Here we reanalyze the free recall
data using the JASP implementation of a classical t test as well as a Bayesian t test.
Journal of Statistical Software 7
Figure 2: A screenshot of the JASP user interface. (A) Data display; (B) Output window;
(C) Menus for analyses.
Figure 3: A classical t test in JASP. (A) List of available variables that can be assigned to
the analysis; (B) The Dependent Variables box is assigned the variable “Critical Recall”; the
Grouping Variable box is assigned the variable “Eye Movement Condition”; (C) Additional
output options; (D) Output.
tion” to the Grouping variable box. The classical t test table is displayed automatically in
the output panel (D).
JASP provides the user with a range of additional output options (C). For instance, clicking
the “Descriptives” option produces the “Group Descriptives” table in the output panel. This
table contains various descriptive statistics such as the group sample sizes. Importantly, the
Group Descriptives table also shows the order of the groups: Results for the Fixation condition
are displayed first, and the results for the Horizontal condition are displayed second. This
order corresponds to Group 1 and Group 2 in the Hypothesis option. Here we clicked the
Group 1 < Group 2 option in order to test the order-restricted alternative hypothesis that
participants in the Fixation condition are expected to recall fewer words on average than do
participants in the Horizontal condition. As shown in the output panel, this one-sided test
results in a p value of 0.997.
Note that clicking additional options immediately adds the corresponding results to the out-
put panel, providing direct feedback to the user. Similarly, unchecking options removes the
corresponding results from the output panel immediately. JASP’s behavior contrasts to that
of most other graphical statistical software, where results are produced in a separate window,
and only after the user has fully specified the analysis and clicked “OK”. Also note that the
output tables conform to the publishing standards of the APA, saving the user the tedious
Journal of Statistical Software 9
Figure 4: A Bayesian t test in JASP. (A) The results from the previous classical t test are
shaded in gray; (B) The results from the current Bayesian t test are highlighted in white.
task of reformatting the output. Placing the mouse cursor over the table presents a menu
with the option to copy, allowing the table to be pasted into a different program such as
Microsoft Word or LibreOffice.
one after another, in a similar fashion. For the present analysis, the standard output contains
a Bayesian t test table that displays the Bayes factor, a Bayesian model selection measure that
quantifies the relative plausibility of the data under the null hypothesis versus the alternative
hypothesis (Berger 2006; Jeffreys 1961; Kass and Raftery 1995). If the option “Prior and
posterior” is checked, then JASP will also report Bayesian parameter estimation results.
The functionality of the Dependent Variables and Grouping Variable boxes, as well as the
Hypothesis, Additional Statistics, and Missing Values options resemble that of the classical
analysis. Additionally, users can select whether they prefer to obtain Bayes factors that
quantify evidence in favor of the alternative hypothesis (BF10 ) or Bayes factors that quantify
evidence in favor of the null hypothesis (BF01 ); finally, users can choose to define one-sided
alternatives (Morey and Rouder 2011; Morey and Wagenmakers 2014).
In the present example, we requested a one-sided Bayes factor in favor of the null hypothesis
(BF01 ) and corresponding density plots of the prior and the posterior distributions. The
output is shown in the right hand panel (B): the Bayes factor equals 16.35, indicating that the
data are more than 16 times more likely under the null hypothesis than under the alternative
hypothesis.
6. Implementation details
The JASP user interface is written in C++, analyses are implemented in the R programming
language (R Core Team 2018), and the results panel is an instance of the WebKit (The WebKit
Open Source Project 2015) browser with the resultant tables and plots rendered in HTML
through JavaScript libraries built on top of Backbone.js (DocumentCloud 2015).
JASP runs as separate processes, with the JASP user interface running in one process, and
the analyses running in separate background processes. This is depicted in Figure 5. When
the user loads a data set such as a CSV file, the user interface (UI) process loads the data
into interprocess shared memory, giving the background processes access to the data as well.
When the user creates an analysis, a new in-memory representation of the analysis is created,
and the analysis is scheduled to be run. If there are no background processes available, for
example, in the case that several analyses are already running, the analysis is added to a
queue. If a background process is available, or becomes available, the waiting analysis is sent
to the background process over shared memory, and a semaphore is set, wakening the process,
and causing the analysis to be run. When the analysis completes, the results are also placed
in shared memory, the UI process collects them from there, and the results panel is populated.
Analyses are performed in two stages; first the analysis is initialized, and subsequently, the
analysis is run. These two stages are controlled by a scheduler, and may not necessarily occur
in the same background process. The intention of the initialization step is to generate empty
results, for example an empty table, immediately providing immediate feedback to the user.
As such, initialization is designed to occur very quickly, and one of the background processes
is reserved solely for initializations so that longer running analyses do not delay this feedback.
Main UI Process
Analysis UI
Results Panel
Scheduler
Background Processes
Figure 5: Conceptual overview of the internal JASP architecture. Analyses are scheduled,
sent to background processes, and the results are sent to the results panel.
interface options, and whether the analysis is being initialized or run. The function is then able
to access the data set residing in shared memory through several native functions provided by
the JASP R environment through the Rcpp (Eddelbuettel and François 2011) and the RInside
(Eddelbuettel and François 2015) packages. These native functions allow the analysis to
request the data as a data frame. Having obtained the data in this way, the analysis marshals
the JASP UI options to the argument forms that underlying R packages expect (A list of R
packages used in JASP is available in Appendix A). Functions from these packages are called,
results objects which are then marshaled into a nested structure of lists representing the
tables and images. This nested list is then returned from the function, where it is converted
into JSON and passed back to the JASP UI process. The JASP UI process passes the
JSON representation of the results to the results panel, which uses JavaScript components
written in Backbone.js to render these results into the results document as HTML elements.
This produces tables and images in the results panel. Note that even though JASP borrows
functionality from R, JASP installs as an independent program. A version of R is bundled
with the JASP installation.
6.2. Callbacks
As described, the JASP R function returns the results as its return value. However, it is
also possible for the analysis to return results while it is running. Similarly, it is possible
for the analysis to respond to changes that the user makes to its options while it is running.
This allows for two important use-cases. While JASP analyses are running, they can provide
partial results as the analysis progresses, and they can receive and respond to changes to the
analysis options. This is achieved through a callback mechanism. The analysis periodically
12 JASP: Graphical Statistical Software for Common Statistical Designs
calls the callback, passing the intermediate results in as an argument, and the callback returns
a value indicating whether the analysis options were changed by the user, and what those
new options are. In this way, the user interface and in-progress analyses can communicate
with one another, and both can respond accordingly.
7. Concluding comments
JASP is a free and open-source statistical package for basic statistics. It is intuitive, user-
friendly, and provides an innovative user experience. The adoption of JASP in preference
to other proprietary statistical packages will enable peer review of the statistical algorithms,
enable scientists to build on existing work, and reduce costs.
Additionally, JASP is based on a unique approach to graphical statistical software, providing
immediate feedback, attractive and minimalist output, and perfect transparency. It is hoped
that JASP will, beyond its immediate contribution as a software package, inspire a new
generation of statistical software based around these principles. Finally, JASP is statistically
inclusive. For the basic statistical scenarios at hand, JASP implements both the classical and
the Bayesian approach. The Bayesian routines in JASP can be used for parameter estimation
and for default Bayes factor hypothesis testing. Our aim is for JASP to unlock the recent
Bayesian developments and make them accessible to a broader audience of researchers and
students.
JASP is available for Windows, Mac OS X and Linux from the project website https://
jasp-stats.org/, and the source code is available from the GitHub repository https://
github.com/jasp-stats/jasp-desktop.
References
Fellows I (2012). “Deducer: A Data Analysis GUI for R.” Journal of Statistical Software,
49(8), 1–15. doi:10.18637/jss.v049.i08.
Fox J (2005). “Getting Started with the R Commander: A Basic Statistics Graphical User
Interface to R.” Journal of Statistical Software, 14(9), 1–42. doi:10.18637/jss.v014.i09.
Fox J, Weisberg S (2011). An R Companion to Applied Regression. 2nd edition. Sage, Thou-
sand Oaks.
Friendly M (2017). vcdExtra: vcd Extensions and Additions. R package version 0.7-1, URL
https://CRAN.R-project.org/package=vcdExtra.
Hankin RKS (2016). hypergeo: The Gauss Hypergeometric Function. R package version 1.2-
13, URL https://CRAN.R-project.org/package=hypergeo.
IBM Corporation (2013). IBM SPSS Statistics 22. IBM Corporation, Armonk. URL https:
//www.ibm.com/software/analytics/spss/.
Jeffreys H (1961). Theory of Probability. 3rd edition. Oxford University Press, New York.
Kass RE, Raftery AE (1995). “Bayes Factors.” Journal of the American Statistical Association,
90(430), 773–795. doi:10.2307/2291091.
Liang F, Paulo R, Molina G, Clyde MA, Berger JO (2008). “Mixtures of g-Priors for Bayesian
Variable Selection.” Journal of the American Statistical Association, 103(481), 410–423.
doi:10.1198/016214507000001337.
Ly A, Verhagen AJ, Wagenmakers EJ (2016). “Harold Jeffreys’s Default Bayes Factor Hy-
pothesis Tests: Explanation, Extension, and Application in Psychology.” Journal of Math-
ematical Psychology, 72, 19–32. doi:10.1016/j.jmp.2015.06.004.
14 JASP: Graphical Statistical Software for Common Statistical Designs
Matzke D, Nieuwenhuis S, Van Rijn H, Slagter HA, Van der Molen MW, Wagenmakers
EJ (2015). “The Effect of Horizontal Eye Movements on Free Recall: A Preregistered
Adversarial Collaboration.” Journal of Experimental Psychology: General, 144(1), e1–e15.
doi:10.1037/xge0000038.
Morey RD, Rouder JN (2011). “Bayes Factor Approaches for Testing Interval Null Hypothe-
ses.” Psychological Methods, 16, 406–419. doi:10.1037/a0024377.
Morey RD, Rouder JN (2018). BayesFactor: Computation of Bayes Factors for Common
Designs. R package version 0.9.12-4.2, URL https://CRAN.R-project.org/package=
BayesFactor.
R Core Team (2018). R: A Language and Environment for Statistical Computing. R Founda-
tion for Statistical Computing, Vienna, Austria. URL https://www.R-project.org/.
Rouder JN, Morey RD (2012). “Default Bayes Factors for Model Selection in Regression.”
Multivariate Behavioral Research, 47(6), 877–903. doi:10.1080/00273171.2012.734737.
Rouder JN, Morey RD, Speckman PL, Province JM (2012). “Default Bayes Factors for
ANOVA Designs.” Journal of Mathematical Psychology, 56(5), 356–374. doi:10.1016/j.
jmp.2012.08.001.
Rouder JN, Speckman PL, Sun D, Morey RD, Iverson G (2009). “Bayesian t Tests for
Accepting and Rejecting the Null Hypothesis.” Psychonomic Bulletin & Review, 16(2),
225–237. doi:10.3758/pbr.16.2.225.
Stevens SS (1946). “On the Theory of Scales of Measurement.” Science, 103(2684), 677–680.
doi:10.1126/science.103.2684.677.
Valero-Mora PM, Ledesma R (2012). “Graphical User Interfaces for R.” Journal of Statistical
Software, 49(1), 1–8. doi:10.18637/jss.v049.i01.
Wickham H (2016). ggplot2: Elegant Graphics for Data Analysis. Springer-Verlag, New York.
ISBN 978-3-319-24277-4.
16 JASP: Graphical Statistical Software for Common Statistical Designs
Note that the R packages used by JASP will change as development progresses. An up-
to-date list of the R packages used and their versions is maintained on the project website:
https://jasp-stats.org/r-package-list/.
Analysis R packages
Affiliation:
Jonathon Love
University of Newcastle
School of Psychology
University Drive, Callaghan
NSW 2308, Australia
E-mail: [email protected]
URL: https://jona.thon.love/