class 6

Hypothesis Testing for One Sample/non-parametric equivalent

Chapter 9: Introduction to the t statistic

9.1: The t statistic: An alternative to z

Recall that last week we learned how to use a sample mean to test hypotheses about an unknown population, based on the following principles:

1) M is expected to approximate ?
2) The ?M determines how much difference is reasonable to expect between M and ?
3) We use these statistics to determine a z-score value in order to quantify our inferences.

Recall that the goal of the hypothesis test of an unknown population is to determine whether the obtained result is significantly greater than would be expected by chance.

But what if you are missing some information about the population...it is after all "unknown"

The problem is in the paradox:
You want to use a z-score to find out about an unknown population but you need to know about the population (for example the ? in order to compute ?M) before you can figure out the z-score.

When the variability for the population is unknown we can use the sample variance in its place to create what is known as the estimated standard error (sM).

sM therefore uses the sample standard deviation (or variance) to provide an estimate between a sample mean (M) and the population mean .

There are two formulas to calculate the estimated standard error:

sM = s or sM = square root of (s2)
?n n

For the purpose of the t statistic, we will concentrate on using only the second formula because 1) the sample variance (s2) will offer an accurate unbiased estimate for the population variance (?2) and 2) other versions of the t statistic require the variance.

In other words we will use the formula:

Estimated standard error = (square root of) sample variance
(over)
sample size
Once we substitute the sM into the denominator we create a new formula which we call the t statistic:

t = M - ?
sM

And so, the t statistic is used to test hypotheses about an unknown population mean ? when the value of ? is unknown using the estimated standard error in the denominator.

The role of Degrees of freedom

degrees of freedom = df = n - 1

Recall that Degrees of freedom (df) describe the number of scores in a sample that are independent and vary. The larger the sample, the greater the value of df. The greater the value of df, the better s2 represents ?2.

Since the t statistic approximates a z-score, then the t distribution itself will also approximate the z score distribution. How well it approximates this will depend on the df. The larger the sample the more closely the t distribution approximates a normal distribution.

Please refer to figures 1.1 and 1.2 attached

SO WHAT DO WE DO WITH THE T-STATISTIC?

Like z-scores, we will use the t-statistic to locate proportions using the t distribution table (APPENDIX B, p.531 in textbook)

  1. determine the df
  2. do you want to know the proportion in one tail or two. One tail proportions are on the top line and two tailed are in the second line
  3. line up the two and there you will find the t-statistic

LETS PRACTICE:

For df = 15 , find the values of t associated with the middle 95% versus the extreme 5% of the distribution

  1. identify column with 0.05 in both tails
  2. locate df = 15
  3. line up the values and you should see t = + 2.131

Please refer to figure 2.1 for further examples

9.2: Hypothesis tests with the t statistic

When the obtained difference between the sample mean and population mean is much greater than expected (sM), we will obtain a large value for t and reject Ho.

In contrast, if the difference between M and ? are small relative to sM, our t statistic will be near zero and we would fail to reject Ho.

This hypothesis test can be broken down into 4 steps:

Step 1: state the hypothesis (Ho and H1) and alpha level
Step 2: compute df (n - 1), locate the critical region and corresponding t value on the t distribution table.
Step 3: Calculate t

t = M - ?
sM
Step 4: make your decision

A COUPLE OF RULES TO FOLLOW:
? values in the sample must consist of independent observations
? the population sampled must be normal

9.3: Measuring Effect Size for the t statistic

There are two methods listed in this section for measuring effect size with the t statistic; Cohen's estimated d and Percentage of variance method

Cohen's estimated d:

Recall that Cohen's d provides a value to determine the effect size of a treatment when compared to the population mean.

Cohen's d = mean difference
(over)
Standard deviation

Now note that this formula requires the standard deviation , however in some cases we do not have the population values in which to compute ?. What we do have is our sample standard deviation (s) which when plugged into the formula can offer us an estimation for the population ?.

The formula for the estimated d:

Estimated d = mean difference = M - ?
(over) s
Sample standard deviation

WHAT DO THE d VALUES REPRESENT?
The closer the value is to 1 the greater the treatment effect
If d = 0.2 it is a small effect
If d = 0.8 - 1.0 there is a large treatment effect

Percentage of Variance Method

A Treatment (or intervention) will cause raw scores to increase, decrease, or stay the same. And so we can say that treatment causes scores to vary.

The principle behind the percentage of variance method is that in theory if we can measure how much of the variability is explained by the treatment, we will then obtain a measure of the size of treatment effect.

The formula uses the sum of squared deviations to determine the "percentage of variance accounted for by the treatment".

r2 is the representing symbol and can be computed as:

r2 = t2
(OVER)
t2 + df

This value is often reported as a percentage.

Say for example r2 = 0.630, then we would say that 63% of the variability within the scores can be accounted for by the treatment effect.

What do the r2 values represent?
Following scale is used to interpret r2
If r2 = 0.01, there is a small effect
If r2 = 0.09, there is a medium effect
If r2 = 0.25, there is a large effect

Remember: the larger the variance, the larger the error, the less likely you are of choosing to reject the null hypothesis. Small variance = more consistency in the distribution of scores.

9.4 Directional Hypothesis and one-tailed tests

Directional or one tailed testing can be used incorporating the t-statistic.

Lets apply the t statistic into one tailed hypothesis test:

Problem: you've noticed that since you started taking Adam's stats class you are having trouble sleeping at night and no longer are getting the 8 beautiful hours of sleep most people get. You are interested in seeing if other people have encounter a similar experience.

You collect a random sample of 20 students who are taking Adam's class and ask them how many hours of sleep they are getting a night.

Summary of statistics: M = 6.5, s = 2.5

Step 1: State the hypothesis and alpha level
H1:: The brave souls enrolled in Adam's class sleep less than most people
Ho: People enrolled in Adam's class sleep the same amount if not more than most people.
Alpha = 0.05
Step 2: Identify the critical region
For one tailed test (as we are hypothesizing that the sample sleeps less then population mean) we use the top row of the table.
Compute df = (n - 1) = 19
Line up the column and row and identify that our cut off value is -1.729
Step 3: Calculate t (note in this case we have a value for ? and do not require an estimate)

t = M - ?
sM

= 6.5 - 8
2.5/ ?19

= -2.613

Step 4: make your decision...what is your decision?

You reject the null hypothesis. Your test statistic is in the rejection region and therefore it is significant. You can conclude that those enrolled in Adam's stats class sleep less than the norm.

And thats it to the t..ha get it?

Nonparametric tests


When the assumptions of the t-tests are seriously violated an alternative approach is to use nonparametric tests.
We are not going to place much emphasis on them in as they are only occasionally used, but you should be aware of them and have some familiarity with them.
These tests do not require the assumption of normality or the assumption of homogeneity of variance. They compare medians rather than means and, if the data have a few outliers, their influence is negated.
Parametric tests are preferred because for the same number of observations, they are more likely to lead to the rejection of a false hull hypothesis - they have more power. This greater power stems from the fact that if the data have been collected at an interval or ratio level, information is lost in the conversion to ranked data (i.e., merely ordering the data from the lowest to the highest value).
The following table gives the non-parametric analogue for the paired sample t-test and the independent samples t-test. There is no obvious comparison for the one sample t-test. Pearson's correlation also has non-parametric alternative (Spearman's correlation) but we will not deal with it further either (more on that later).
There are a wide range of alternatives for the two group t-tests, the ones listed are the most commonly use ones and are the defaults in SPSS. Generally, running nonparametric procedures is very similar to running parametric procedures, because the same design principle is being assessed in each case. So, the process of identifying variables, selecting options, and running the procedure are very similar. The final p-value is what determines significance or not in the same way as the parametric tests. SPSS gives the option of two or three analogues for each type of parametric test, but you need to know only the ones cited in the table. Same practice with these tests may given in Assignment 2.

Parametric test
Non-parametric analogue
One-sample t-test
Nothing quite comparable
Paired sample t-test
Wilcoxon T Test
Independent samples t-test
Mann-Whitney U Test
Pearson's correlation
Spearman's correlation
 

Class 4-8 Objectives

At the conclusion of these classes, you should be able to:


Prepare data for analysis using Transform, Recode, and Compute to:

Reverse-scale a variable

-          Compute a total scale

-          Create a standard scale score

-          Create a qualitative variable from one or more quantitative variables

                      

Describe qualitative variables using the Frequencies procedure

Create a bar chart to display frequencies

Create a pie chart to display frequencies

Identify appropriate formats (table, bar chart, pie chart) to use when presenting qualitative variables

Describe quantitative variables using statistical indices, including measures of:

-          Central Tendency

-          Variability

-          Skewness

-          Kurtosis

Create charts to visually represent variables, including:

-          Histograms

-          Boxplots

-          Error bar charts

-                      Convert raw scores to z-scores

Conduct a one-sample t-test

Summarize the assumptions underlying a one-sample t-test

Create a histogram chart to present the results of a one-sample t-test

Explain the results of a one-sample t-test

Conduct a paired-sample t test

Summarize the assumptions underlying a paired-sample t-test

Create a box plot chart to present the results of a paired-sample t-test

Explain the results of a paired-sample t-test

Apply an independent-samples t-test

Summarize the three assumptions underlying a independent-samples t test

Create an error bar graph and a box plot chart to present the results of an independent-samples t-test

Explain the results of an independent-samples t-test

Class 6 Reviewed.  Ruth Robbio

Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.