Download Two group t-test

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Regression analysis wikipedia , lookup

Regression toward the mean wikipedia , lookup

Linear regression wikipedia , lookup

Coefficient of determination wikipedia , lookup

Resampling (statistics) wikipedia , lookup

Data assimilation wikipedia , lookup

Transcript
From t-test to multilevel analyses
Del-1
Stein Atle Lie, statistician, professor
Uni Health, Uni Research
http://folk.uib.no/msesl/GLM
Outline
 Pared t-test (Mean and standard deviation)
 Two-group t-test (Mean and standard deviations)
 Linear regression
 GLM (general linear models)
 GLMM (general linear mixed model)
…
 PASW (former SPSS), Stata, R, gllamm (Stata)
Multilevel models
 “Same thing – many names”:
 Random effects models
 Mixed effects models
 Variance component models
 Frailty models (in survival analyses)
 Latent variables
Objective
 Take the general thinking from simple statistical
methods into more sophisticated datastructures and statistical analyses
 Focus on the interpretation of the results with
respect to those found in basic statistical
methods
Multilevel data
Types of data:
 Repeated measures for the same individual
 The same measure is repeated several times on the
same individual
 Several observers have measured the same
individual
 Several different measures for the same individual
 A categorical variable with ”many” levels
(multicenter data, hospitals, surgeons,…)
Null hypotheses
 In ordinary statistics (using both pared and
two-sample t-tests) we define a null hypothesis.
H0: m1 = m2
 We assume that mean from group (or measure) 1
is equal to the mean from group (or measure) 2.
 Alternatively
H0: D = m1-m2 = 0
p-value
 Definition:
 “If our null-hypothesis is true - what is the
probability to observe the data* that we did?”
* And hence the mean, t-statistic, etc…
p-value
 We assume that our null-hypothesis is true
(m0=0 or m1-m2=0)
 We observe our data
 Mean value etc.
 Under the assumption of normal distributed data
p-value
 The p-value is the
probability to observe
our data (or something
more extreme) under
the given assumptions
-2
0
X
2
m0
4
6
8
X
Pared t-test
 The straightforward way to analyze two
repeated measures is a pared t-test.
 Measure at time1 or location1 (e.g. Data1) is
directly compared to measure at time2 or
location2 (e.g. Data2)
 Is the difference between Data1 and Data2
(Diff = Data1-Data2) unlike 0?
Pared t-test (n=10)
PASW:
T-TEST PAIRS=Data1 WITH Data2 (PAIRED).
Pared t-test
 The pared t-test will only be performed for
complete (balanced) data.
 What happens if we delete two observations
from data2?
 (Only 8 complete pairs remain)
Pared t-test (n=8)
PASW:
T-TEST PAIRS=Data1 WITH Data2 (PAIRED).
Excel
Two group t-test
 If we now consider the data from time1 and
time2 (or location1 and location2) to be
independent (even if their not) and use a two
group t-test on the full dataset, 2*10
observations
Two group t-test (n=20 [10+10])
PASW:
T-TEST GROUPS=Grp(1 2)
/VARIABLES=Data.
Two group t-test
 Observe that mean for Grp1 and Grp2 is equal
to mean for Data1 and Data2
 And that the mean difference is also equal
 The difference between pared t-test and two
group t-test lies in the
 Variance - and the number of observations
 and therefore in the standard deviation and
standard error
 and hence in the p-value and confidence intervals
Two group t-test
 The two group t-test are performed on all
available data.
 What happens if we delete two observations
from Grp2?
 (Only 8 complete pairs remain - but 18
observations remain)
Two group t-test (n=18 [10+8])
PASW:
T-TEST GROUPS=Grp(1 2)
/VARIABLES=Data.