anova Flashcards

1
Q

when might we use a one-way ANOVA Examples:

A
  • Is there a difference in the average spend per patient when treating different levels of depression severity (mild, moderate, or severe)?
  • Does smoking history (non smoker, light smoker, heavy smoker) affect how far you can run?
  • Is there a difference amongst different age groups (children, adolescent, adults and older adults) in how long they attend to visual stimuli?
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Features of the data for one way ANOVA

A

One independent variable with three (or more) groups (conditions/levels)
One dependent variable measured using normally distributed data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is A one-way way anova?

A

ANOVA: ANalysis Of VAriance
A statistical technique that compares the variance within samples and the variance between samples in order to estimate the significance of differences between a set of means.
- One independent variable

A one-way ANOVA is used to examine the difference amongst three or more groups on one continuous, normally distributed variable.
A one-way ANOVA examines the variance between these groups, whilst also controlling for the variance within groups.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

factors

A

Independent variable(s) e.g. depression severity

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

levels/conditions

A

Categories in each factor e.g. mild, moderate or severe

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

effects

A

Quantitative measure indicating the difference between levels/conditions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Type 1 error

A

Incorrectly rejecting the null hypothesis (false positive)
In other words:
Getting a significant result when there’s no real effect in the population
More likely with:
Multiple Comparisons
e.g. Doctors find a significant effect of the drug on pain relief. When in fact the true effect is that the drug does not relieve pain. The null hypothesis is incorrectly rejected.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

type 2 error

A

Incorrectly failing to reject a false null hypothesis (false negative)

In other words:
Not finding a significant effect when there actually is one in the population

More likely with Small sample sizes

e.g. Type 2 Error:
Doctors find no significant effect of the drug on pain relief. When in fact the true effect is that the drug does relieve pain. The null hypothesis is incorrectly accepted.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Multiple Comparisons – Why is multiple testing a problem?

A

● If we adopt an α level of 0.05, then assuming the null hypothesis (H0 is true, then 5% of the statistical tests would show a significant difference or association.
● The more tests we run, the greater likelihood that at least 1 of those tests will be significant by chance (Type 1 error).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

When can issues surrounding multiple testing arise?

A

● Looking for differences amongst groups on a number of outcome measures
● Analysing your data before data-collection has finished (and then re-analysing it at the end of data collection).
○ This violation is often used to see whether more data need to be collected to reach significance.
● Unplanned analyses i.e. conducting additional analyses to try and find something of interest…

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

How to address issues of multiple testing

A
  1. Avoid over-testing (plan your analyses in advance)
  2. Use appropriate tests
  3. In instances where multiple tests are run, adjust the α threshold (more on this next week).
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Multiple comparisons vs ANOVA

A

● Multiple comparisons runs the risk of a Type 1 error (false positive)
● ANOVA allows us to examine the differences between multiple groups as whole, rather than running lots of different tests.
○ If we find a significant effect in our ANOVA, we can then do further investigations to find out where the difference lies with adjustments for multiple comparisons (more on this next week).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

f statistic

A

● F Statistic is essentially a ratio of two variances, these are also referred to as mean squares.
● Mean squares are variances that account for the degrees of freedom
● The F statistic, along with degrees of freedom are used to then calculate the p-value

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

low f statistic

A

The group means cluster together more tightly than the within group variability

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

low f statistic

A

The group means spread out more than the variability within groups.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

One-way anova: Degrees of freedom

A

To get a better understanding of degrees of freedom, watch the YouTube video linked on NOW.
● A one-way ANOVA uses two degrees of freedom
Degrees of freedom 1 = Number of independent groups – 1
Degrees of freedom 2 = Sample size – the number of independent groups

17
Q

Follow up comparisons

A

● Many different follow up comparison methods to explore main effects i.e., where does the difference lie?
We will look at two:
1. Bonferroni corrected t-test
2. Tukey’s HSD

18
Q

t-test with Bonferroni comparison

A

● We reject the null hypothesis when p

19
Q

Bonferroni Correction:

A

We adjust the alpha level for our rejection of the null hypothesis. This alpha level is based on the number of comparisons.
α=.05/number of comparisons

20
Q

Tukey’s HSD

A

also known as Tukey’s honest significant difference test. This post-hoc comparison test compares the compare the difference between means of values. Specifically, the value of Tukey’s test is given by taking the absolute value of the difference between a pair of means and dividing it by the standard error of the mean (SE). The standard error is in turn the square root of the variance divided by the sample size. This test also adjusts for type 1 errors. Below are the outcomes of a Tukey’s HSD for our data. We have the difference values followed by the adjusted p-values.
Tukey’s HSD = (〖Mean〗_1 -〖Mean〗_2)/√(〖MS〗_Error/n)

21
Q

Which correction?

A

Short answer…

  1. A priori (planned comparisons) = Bonferroni
  2. Post Hoc (unplanned comparisons) = Tukey’s HSD
22
Q

r studio anova

A

model

23
Q

r studio bonferroni correction

A

pairwise_t_test (dataset ~ dataset, data = data, p_adj = “Bonferroni”)