Let's learn how to compute the three measures of central tendency: mean, median, and mode using JASP.
For this example we will use the data set StatsClass.SAV
Begin by placing the data set on your computer desktop.
Once you have JASP open, we will open the file by going to our Main Menu icon -> Open ->
Computer -> Desktop. Locate the StatsClass.SAV data set and click Open.
Notice that this is actually an SPSS data set. JASP can open a .SAV file
directly, as well as CSV data sets, but not an Excel file. Those have to be
converted into .CSV, first.
As you can see, JASP has read the file and is showing you the data. We are
interested in the variables "IQ": a measure of intelligence, and "StatATT":
a measure of attitudes about statistics. JASP has correctly interpreted the
level of measurement for both of these variables as Scale, so we are ready to go.
Central tendency is a descriptive statistic, so we will be using this
Descriptives menu. Select the option for Descriptive Statistics. In the Results
pane we already see the table where the descriptive statistics are going to
appear. Move the variables standardized IQ scores or "IQ" and attitudes towards
statistics or "StatATT" into the variables box. Here we see the JASP progressive
disclosure. The results appear as soon as we enter the variables; however, we do not
yet have all of the measures of central tendency that we will need... but it's easy
enough to add them. Click on the disclosure triangle next to Statistics.
Here we find a list of available statistics for our variables. We want
mean, median, and mode. As we click on them, each measure of central tendency is
added to our existing Descriptive Statistics table. Because this
introductory lecture is only about central tendency, we have measures of
dispersion that we do not need right now. To turn off any option, we simply
deselect the box. Of course, as we put these statistical pieces together, moving
forward, we will always want to combine our measures of central tendency with a
measure of dispersion... and we will do that in all future examples. Now we can
examine the results. Our first variable is Standardized IQ Scores. Look at the
mean, median, and mode: 97.69, 97.3, & 97.3
Now look at the "Attitudes towards
statistics" scores: this time the mean, median, and mode are 5.64, 6.0, & 1.0
So here is my question for you: which of these two variables is
normally distributed... and how can you tell?
The key is to look at the three measures of central tendency. The mean, median, and
mode for IQ scores are very, very similar; whereas, for attitudes towards statistics,
these three measures of central tendency are not even close. This tells us that
"attitude" is not normally distributed but "IQ" IS normally distributed. But let's
prove this to ourselves. It could be helpful to see a histogram of both of
these distributions. To get a sense for how they look,
click the disclosure triangle next to Plots. We would like to see the
Distribution plots. This shows us some histograms. We can get even more
information by adding the Density of the distribution. We now see the results.
I said that IQ scores should be normally distributed, based on the fact that the
mean, median, and mode were almost the same...and what do we see? The density
curve for IQ scores looks pretty much like a normal curve. We clearly have an
outlier or two on the upper end, but otherwise density looks normal. It would
be rare that a distribution looks EXACTLY like a normal curve, but this is
close enough to a normal distribution. In fact, we might say that this distribution
"satisfies the assumption of normality." It is approximately normally distributed.
But what about "Attitude towards Statistics"? We said that it would NOT
be normally distributed... so let's check it out. Notice that neither the histogram
nor the density curve looks anything like a normal curve. Normality is
something that we can see both mathematically and with pictures.
Both the numbers and the plot agree: this variable is not normally distributed.
So as a bonus let, me show you a few other things that you can do with JASP.
With progressive disclosure, it is easy to add plots or analyses. So for example,
let's add the Correlation Plots. Here we see a correlation of our two variables.
Not surprisingly, IQ and stats attitudes are weakly positively correlated. And we
see some other familiar distribution plots. Now, the great thing about JASP is
that you can add new analyses or plots, and you never need to worry that you're
going to break something. For example, let's look at the box plots.
The box plots do not tell us as much about the shape of the distribution as
the histogram did, but they do show us the spread or the dispersion... and they
help us identify outliers. Remember we said that there were some outliers with
the IQ scores? If we label the outliers, we can learn their case numbers. We can
also add Color, a Violin element, and what is called a Jitter element, that allows
us to see the data points more clearly. We will learn more about these elements
later, but for now feel free to experiment with turning on or off the output.
Down here we have Q-Q plots.
These plots help us to determine the normality of a distribution. If the dots
are ON a straight line, the variable is normally distributed, as we see here with IQ.
But if the dots are OFF of the line, as with statistics attitude, the variable
is NOT normally distributed. I think that I want to keep the Q-Q plots, but I do not
want the box plots, or the correlation plots. I simply deselect those boxes and
the results go away. Or if I change my mind, I can add them back easily.
One more thing: let's look at that table again.
JASP makes it easy to split an analysis by a categorical variable. So let's say that
we want to examine the scores for males and females separately. Move the variable
Gender into the Split box. Now we can see the same central tendency results except
separated by scores for males and females. We could do the same thing for a
categorical variable with multiple levels, such as class standing: freshman,
sophomore, junior, senior. Finally, you can save this file as JASP dataset by
going to Save as -> Computer -> Desktop and saving it as StatsClass.
The new file will appear on your desktop as StatsClass.jasp
not only will it contain your numeric data it will also contain all of the
analysis and the plotting that you have done so far so this is how you calculate
central tendency in Jasper