Random Intercept Models

Size: px
Start display at page:

Download "Random Intercept Models"

Transcription

1 Random Intercept Models Edps/Psych/Soc 589 Carolyn J. Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Spring 2019

2 Outline A very simple case of a random intercept model. When to use this model The model Empty model One explanatory variable Multiple explanatory variables Next: SAS and R overview followed by computer lab 1. Reading: Snijders & Bosker, pp C.J. Anderson (Illinois) Random Intercept Models Spring / 80

3 A Simple Model Situation: j = 1,...,N groups (e.g., schools). i = 1,...,n j individuals within the groups (e.g., students). Y ij a numerical response variable (e.g., math scores). x ij a possible explanatory variable (e.g., SES). C.J. Anderson (Illinois) Random Intercept Models Spring / 80

4 Simple Level 1 Model Y ij = β 0j +β 1 x 1ij +R ij where β 1 is fixed in the population. R ij N(0,σ 2 ) and independent. The intercept, β 0j, depends on the group. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

5 Simple Level 2 Model The intercept, β 0j, can be broken down into two parts: An overall or average value of the intercept: γ 00 A group dependent part of the intercept: The Level 2 Model is U 0j β 0j = γ 00 +U 0j C.J. Anderson (Illinois) Random Intercept Models Spring / 80

6 The Linear Mixed Model Replace β 0j in the level 1 model by the level 2 model for β 0j : Y ij = γ 00 +U 0j +β 1 x 1ij +R ij = γ 00 +U 0j +γ 10 x 1ij +R ij where β 1 = γ 10 (to be consistent with later models). C.J. Anderson (Illinois) Random Intercept Models Spring / 80

7 NELS88 Data What the model might look like applied to the NELS88 data (N = 10 schools): C.J. Anderson (Illinois) Random Intercept Models Spring / 80

8 Two cases of the model Y ij = γ 00 +γ 10 x 1ij +U 0j +R ij Case 1: ANCOVA If the U 0j s are fixed parameters in the population (i.e., The U 0j s are not random but are the group effects). Case 2: Random intercept model (i.e., HLM) If the U 0j s are random; that is, groups are a random sample in the population. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

9 Contrasting ANCOVA & HLM ANCOVA/ANOVA: Groups are unique and interest is only in the groups observed. A Group s observations provide information about U 0j, so with small n j, don t get precise estimates of group effects (large standard errors). InANCOVA, U 0j srepresentallthe differences between groups (no unexplained variability left). If U 0j and R ij are non-normal and/or dependent, random coefficient model may be unreliable. Random Coefficients Model: Groups are a sample from a (real or hypothetical) population and Group effects come from the same distribution, data from all groups is used= candowellwithsmalln j. Synonyms: random effects & unexplained variability i.e., U 0j N(0,τ0 2 ), groups are exchangeable. Can use a different distribution. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

10 Random Intercept Model: no x s The baseline/empty/null HLM (no explanatory variables). A regression model where the intercept is a random variable. Models for Clustered Data Level 1: Y ij = β 0j +R ij where R ij N(0,σ 2 ), and independent. The intercept, β 0j, is a random variable for which we specify a linear regression model (level 2, e.g., groups). Level 2: β 0j = γ 00 +U 0j where γ 00 is the intercept (fixed). U 0j N(0,τ0 2 ) and independent. U 0j and R ij are independent. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

11 Levels 1 and 2 Estimation of level 1 and level 2 models should be simultaneous. Substituting our equation for β 0j (level 2 model) into the equation for level 1, we get a composite or linear mixed model and the marginal model is Y ij = β oj +R ij = γ 00 }{{} +U 0j +R ij }{{} fixed random Y ij N(γ 00,(τ 2 0 +σ2 )) C.J. Anderson (Illinois) Random Intercept Models Spring / 80

12 Estimation Y ij = β oj +R ij = γ 00 }{{} +U 0j +R ij }{{} fixed random and Y ij N(γ 00,(τ 2 0 +σ 2 )) This (marginal model) is what is used to fit the model to data and in SAS/MIXED or R, we specify the linear mixed model. To use HLM7 software, you specify the component models (i.e., the level 1 model, and the level 2 models) and the program figures out what the marginal model is and fits it to the data. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

13 Example: Null Model High School and Beyond: A nationally representative sub-sample from the 1982 High School and Beyond Survey. It includes Information on n + = 7185 students. Students are nested within N = 160 schools: 90 public and 70 Catholic. Samples sizes averaged about n j 45 per school. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

14 Example: Level 1 Level 2 variables Level 1 Variables: Student level variables Outcome variable: Math achievement. Explanatory: Student socioeconomic status (SES) composite of parental education, occupation and income. This have been standardized such that average equals 0. Student ethnicity (1=minority, 0=not). Gender (1=female, 0=male). Level 2 Variables: School level variables Sector whether the school is Catholic (= 1) or public (= 0). Mean SES average SES of students w/in a school. School enrollment. Proportion of students in academic track. Disciplinary climate. Whether the percentage minority is 40% or > 40%. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

15 Example: the null HLM Y ij = math achievement. Groups are schools: j = 1,...,160. Diagram representing the situation:... math C.J. Anderson (Illinois) Random Intercept Models Spring / 80

16 The Hierarchical Null Model Level 1: Y ij = β 0j +R ij (math) ij = β 0j +R ij where R ij N(0,σ 2 ) and independent. Level 2: β 0j = γ 00 +U 0j where U 0j N(0,τ0 2 ) and independent....and R ij and U 0j are independent. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

17 The Marginal Model The Linear Mixed model: (math) ij = Y ij = γ 00 +U 0j +R ij where U 0j and R ij are independent and The Marginal Model: Y ij N(γ 00,(τ0 2 +σ 2 )). Implications for data. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

18 Results 1 Some descriptive statistics: The MEANS Procedure Variable Label Mean StdDev mathach Mathematics achievement ses standardized student ses Or in R, means(mathach), sd(mathach), where mathach is the name of math scores in hsb dataframe. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

19 Results 2 The Mixed Procedure Model Information Data Set SASDATA.HSBALL Dependent Variable mathach Covariance Structure Variance Components Subject Effect id Estimation Method ML Residual Variance Method Profile Fixed Effects SE Method Model-Based Degrees of Freedom Method Containment C.J. Anderson (Illinois) Random Intercept Models Spring / 80

20 Results 3 Dimensions Covariance Parameters 2 Columns in X 1 Columns in Z Per Subject 1 Subjects 160 Max Obs Per Subject 67 Observations Used 7185 Observations Not Used 0 Total Observations 7185 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

21 Results 4 Iteration History Iteration Evaluations -2 Log Like Criterion Convergence criteria met. Covariance Parameter Estimates Standard Z Cov Parm Subject Estimate Error Value Pr Z > t Intercept id <.0001 Residual <.0001 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

22 Results 5 Fit Statistics -2 Log Likelihood AIC (smaller is better) AICC (smaller is better) BIC (smaller is better) Solution for Fixed Effects Standard Effect Estimate Error DF t Value Pr > t Intercept <.0001 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

23 Summary of Results Null Model Parameter Value SE Parameter Value SE γ τ σ Estimate of the intra-class correlation, ˆρ I = ˆτ 2 ˆτ 2 + ˆσ 2 = = =.18 and ( math) ij = 12.64, the overall (total sample) mean, The overall variance of math scores is s 2 = ( ) = Note s = and s 2 = see descriptive statistics, p 18. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

24 Add SES as Level 1 Explanatory? C.J. Anderson (Illinois) Random Intercept Models Spring / 80

25 Some More Schools C.J. Anderson (Illinois) Random Intercept Models Spring / 80

26 Overlay Regressions for all Schools C.J. Anderson (Illinois) Random Intercept Models Spring / 80

27 Random Intercept: One x SES to help explain some of the variability of Y ij. The Hierarchical Model: Level 1: Y ij = β 0j +β 1j x ij +R ij where R ij N(0,σ 2 ) and independent. Level 2: β 0j = γ 00 +U 0j β 1j = γ 10 where U 0j N(0,τ0 2 ) and independent (and independent w/rt R ij ). C.J. Anderson (Illinois) Random Intercept Models Spring / 80

28 Random Intercept: 1 x The appropriate diagram to represent this model?... SES ij math ij or more generally... x ij y ij C.J. Anderson (Illinois) Random Intercept Models Spring / 80

29 Random Intercept: 1 x The Linear Mixed Model: Y ij = γ 00 +γ 10 x ij +U 0j +R ij where γ 00 is the intercept for the average group. γ 10 is regression coefficient for x ij (fixed). U 0j N(0,τ0 2 ) and independent. R ij N(0,σ 2 ) and independent. U 0j and R ij are independent. Notes: var(y ij x ij ) = var(u 0j )+var(r ij ) = τ 2 0 +σ2 cov(y ij,y i j x ij,x i j) = τ 2 0 Residual intra-class correlation, ρ I (Y X = x) = τ2 0 τ 2 0 +σ2 If τ0 2 = 0, then simply use ordinary linear regression (OLS). C.J. Anderson (Illinois) Random Intercept Models Spring / 80

30 Marginal vs Hierarchical Model The Marginal Model: Y ij N(γ 00 +γ 10 x ij,(τ 2 o +σ 2 )) The hierarchical model implies the marginal model. The marginal model does not imply the hierarchical model. There are no random effects in the marginal model. The HLM is more restrictive than the marginal. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

31 Linear Mixed Model in Matrix Notation The linear mixed model, Y ij = γ 00 +γ 10 x ij +U 0j +R ij, In matrix notation, for marco unit (group) j, Y 1j Y 2j. Y njj = 1 x 1j 1 x 2j.. 1 x njj ) γ 10 + ( γ ( U 0j )+ R 1j R 2j. R njj Y j = X j Γ + Z j U j + R j C.J. Anderson (Illinois) Random Intercept Models Spring / 80

32 Marginal Model in Matrix Notation And the marginal model is Y j N(X j Γ,(Z j TZ j +σ 2 I)). Note that Z j TZ j is just (n j n j ) τ 2 τ 2... τ 2 1τ 2 1 τ 2 τ 2... τ 2 = τ 2 τ 2... τ 2 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

33 Example: HSB x ij = SES ij (student/micro level). Some descriptive statistics: The MEANS Procedure Variable N Mean Std Dev Mathematics achievement Standardized student ses C.J. Anderson (Illinois) Random Intercept Models Spring / 80

34 Edited output from SAS/MIXED The Mixed Procedure Model Information Data Set SASDATA.HSBALL Dependent Variable mathach Covariance Structure Unstructured Subject Effect id Estimation Method ML Residual Variance Method Profile Fixed Effects SE Method Model-Based Degrees of Freedom Method Containment C.J. Anderson (Illinois) Random Intercept Models Spring / 80

35 Example: HSB Dimensions Covariance Parameters 2 Columns in X 2 Design for fixed Columns in Z Per Subject 14 Design for random Subjects 160 N Max Obs Per Subject 67 largest n j Observations Used 7185 n + Observations Not Used 0 Total Observations 7185 Convergence criteria met. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

36 Proc MIXED Output Covariance Parameter Estimates Standard Z Cov Parm Subject Estimate Error Value Pr Z UN(1,1) id <.0001 Residual <.0001 Solution for Fixed Effects Standard Effect Estimate Error DF t Value Pr > t Intercept <.0001 ses <.0001 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

37 Summary & Comparison Null Model Add SES Value SE Value SE Fixed effects γ γ Random effects τ σ Residual intra-class correlation, ˆρ I (math SES) = = =.11 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

38 Comparison Drop in between groups variance estimate ˆτ 2 0 : 4.73 =.55 or (1.56)100 = 45% descrease 8.55 Drop in within groups variance estimate ˆσ 2 : =.95 or (1.95)100 = 5% descrease Interpretation somewhat problematic because SES helps to explain both the between and within groups variance of Y ij : SES ij = SES j +(SES ij SES j ) C.J. Anderson (Illinois) Random Intercept Models Spring / 80

39 Problematic Interpretation... Between versus Within Group Regressions. Different processes at work at different levels. An example: C.J. Anderson (Illinois) Random Intercept Models Spring / 80

40 Problematic Interpretation (continued) Within individual: Child s reading ability improves with instruction. Between individuals: Children get tutoring/private instruction for different reasons. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

41 Returning to the HSB Example Groups differ with respect to mean SES (i.e., SES j ). C.J. Anderson (Illinois) Random Intercept Models Spring / 80

42 Returning to the HSB Example Individual students within schools differ with respect to SES. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

43 Returning to the HSB Example Or for just one school, we have within school variability, Line is simple linear regression line. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

44 Solution to Problem Regarding different mean levels of SES between and within schools: Group mean centered variable, e.g., x ij = (SES ij SES j ) to model within group variability of Y ij w/rt SES. Group mean as a level 2 (school) variable z j = SES j C.J. Anderson (Illinois) Random Intercept Models Spring / 80

45 Solution to Problem (continued) Recall that overall mean SES = 0. First we ll just have a level 1 (student) variable for SES: x ij = (SES ij SES j ) A diagram for this model,... (SES ij SES j ) math ij C.J. Anderson (Illinois) Random Intercept Models Spring / 80

46 Add Centered SES at Level 1? C.J. Anderson (Illinois) Random Intercept Models Spring / 80

47 Some More Schools C.J. Anderson (Illinois) Random Intercept Models Spring / 80

48 Overlay Regressions for all Schools C.J. Anderson (Illinois) Random Intercept Models Spring / 80

49 Hierarchical Model with Centered SES Level 1: Y ij = β 0j +β 1j x ij +R ij math ij = β 0j +β 1j (SES ij SES j )+R ij where R ij N(0,σ 2 ) and independent. Level 2: β 0j = γ 00 +U 0j β 1j = γ 10 where U 0j N(0,τ0 2 ) and independent. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

50 Linear Mixed & Marginal Models The corresponding linear mixed model: math ij = γ 00 +γ 10 (SES ij SES j )+U 0j +R ij and Marginal Model: math ij N(γ 00 +γ 10 (SES ij SES j ),(τ 2 0 +σ2 )). C.J. Anderson (Illinois) Random Intercept Models Spring / 80

51 Edited SAS/MIXED Output Convergence criteria met. Covariance Parameter Estimates Standard Z Cov Parm Subject Estimate Error Value Pr Z UN(1,1) id <.0001 Residual <.0001 Solution for Fixed Effects Standard t Effect Estimate Error DF Value Pr > t Intercept <.0001 cses <.0001 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

52 Estimated Overall Regression Line math ij = (SES ij SES j ) C.J. Anderson (Illinois) Random Intercept Models Spring / 80

53 Sub-Sample of Groups Lines math ij = (SES ij SES j )+Ûj C.J. Anderson (Illinois) Random Intercept Models Spring / 80

54 Model Summary & Comparison Null Model Add SES Add cses Value SE Value SE Value SE Fixed effects γ γ Random effects τ σ C.J. Anderson (Illinois) Random Intercept Models Spring / 80

55 Conclusion Residual intra-class correlation, ˆρ I (math SES) = = =.19 It appears that SES account for some variability in math achievement, Y ij, within schools ( ) 100% = (1.945)100% = 5.5% Does z j = SES j help model between group variability? C.J. Anderson (Illinois) Random Intercept Models Spring / 80

56 Between School Variability & SES Using SES j as predictor for β oj. The Û0j s plotted below are from Y ij = (γ 00 +U 0j ) +γ 10(SES ij SES j )+R ij }{{} β 0j C.J. Anderson (Illinois) Random Intercept Models Spring / 80

57 HLM with x and z Level 1: math ij = β 0j +β 1j (SES ij SES j )+R ij where R ij N(0,σ 2 ). Level 2: Linear Mixed Model β 0j = γ 00 +γ 01 (SES j )+U 0j β 1j = γ 10 where U 0j N(0,τ0 2 ) and independent. math ij = γ 00 +γ 10 (SES ij SES j )+γ 01 (SES j )+U 0j +R ij C.J. Anderson (Illinois) Random Intercept Models Spring / 80

58 Guessing What Will Happen math ij = (SES ij SES j )+U 0j +R ij Put in regression of Û 0j on SES j into above: Y ij = (SES ij SES j )+( (SES j )+U 0j)+R ij = (SES ij SES j )+5.344(SES j )+U 0j +R ij How about a new τ 0? The R 2 between Û0j & SES j equaled.623 and previously estimated ˆτ 0 = ˆτ 0 ˆτ 0 ˆτ 0 R ˆτ ˆτ C.J. Anderson (Illinois) Random Intercept Models Spring / 80

59 Theory and Proposition In terms of a diagram, our proposition (theory), SES j...ց... (SES ij SES j ) math ij Micro-micro: Higher a student s SES relative to the school mean, the higher his/her math score. Macro-micro: Higher average SES of school, higher a student s math score. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

60 Edited SAS/MIXED Output Dimensions Covariance Parameters 2 Columns in X 3 *** this changed Columns in Z Per Subject 1 Subjects 160 Observations Used 7185 Observations Not Used 0 Total Observations Convergence criteria met.. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

61 Edited SAS/MIXED Output Covariance Parameter Estimates Standard Z Cov Parm Sub Estimate Error Value Pr Z UN(1,1) id <.0001 Residual <.0001 Solution for Fixed Effects Standard t Effect Estimate Error DF Value Pr> t Intercept <.0001 cses <.0001 meanses <.0001 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

62 Summary Models Fit to HSB Null, empty, baseline, math ij = γ 00 +U 0j +R ij 1 uncentered variable, math ij = γ 00 +γ 10 (SES) ij +U 0j +R ij Group centered, math ij = γ 00 +γ 10 (SES ij SES j )+U 0j +R ij Group centered and mean, math ij = γ 00 +γ 10 (SES ij SES j )+γ 01 (SES j )+U 0j +R ij C.J. Anderson (Illinois) Random Intercept Models Spring / 80

63 Summary of Parameter Estimates Add cses ij Null Model Add (SES) ij Add cses ij & (SES) j Value SE Value SE Value SE Value SE Fixed effects γ γ γ Random effects τ0 2 (between) σ 2 (within) Note: cses ij = (SES) ij (SES) j SES j = (1/n j ) n j i=1 (SES) ij C.J. Anderson (Illinois) Random Intercept Models Spring / 80

64 Two more models Add all the student level variables that we have to see if we can account for more of the within groups residual variance. i.e., Add more x ij s to the model. SES ij SES j female (= 1 if female, = 0 if male) minority (= 1 if minority, = 0 if not) Add all the school level variables to see if we can account for more between groups residual variance. i.e., Add more z j s to the model. himinty = 40% minority, 0 =< 40% minority pracad = Proportion of students in academic track disclim = Disciplinary climate sector = 1 = Catholic, 0 = public size =school enrollment C.J. Anderson (Illinois) Random Intercept Models Spring / 80

65 HLM with Lots of Micro Variables Level1 : (math) ij = β 0j +β 1j (SES ij SES j ) where R ij N(0,σ 2 ) and independent. +β 2j (female) ij +β 3j (minority) ij +R ij Level2 : β 0j = γ 00 +γ 01 (SES) j +U 0j β 1j = γ 10 β 2j = γ 20 β 3j = γ 30 where U 0j N(0,τ0 2 ) and independent. R ij and U j are independent. Homework: What s the linear mixed model? What s the marginal model? C.J. Anderson (Illinois) Random Intercept Models Spring / 80

66 Edited SAS/MIXED output The Mixed Procedure Model Information Data Set WORK.HSBCENT Dependent Variable mathach Covariance Structure Unstructured Subject Effect id Estimation Method ML Residual Variance Method Profile Fixed Effects SE Method Model-Based Degrees of Freedom Method Containment C.J. Anderson (Illinois) Random Intercept Models Spring / 80

67 Edited SAS/MIXED output Dimensions Covariance Parameters 2 Columns in X 7 Columns in Z Per Subject 1 Subjects 160 Max Obs Per Subject 67 Observations Used 7185 Observations Not Used 0 Total Observations 7185 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

68 Edited SAS/MIXED output Convergence criteria met. Covariance Parameter Estimates Standard Z Cov Parm Subject Estimate Error Value Pr Z UN(1,1) id <.0001 Residual <.0001 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

69 Edited SAS/MIXED output Solution for Fixed Effects Student student ethnicity gender (1=minority, (1=female, Standard Effect 0=not) 0=male) Estimate Error Intercept cses minority minority 1 0. female female 1 0. meanses C.J. Anderson (Illinois) Random Intercept Models Spring / 80

70 Note: cses ij = (SES) ij (SES) j SES j = (1/n j ) n j i=1 (SES) ij C.J. Anderson (Illinois) Random Intercept Models Spring / 80 Simple Model Contrast ANCOVA & HLM Empty Model 1 Explanatory Multiple Explanatory Variables Summary Summary & Comparison Add cses ij Add all Null Model Add cses ij & (SES) j mirco level Value SE Value SE Value SE Value SE Fixed effects intercept centered SES male not minority mean SES Random effects τ0 2 (between) σ 2 (within)

71 Lots of Macro-level Variables Add all of the school (macro-level) variables: himinty = 40% minority, 0 =< 40% minority pracad = Proportion of students in academic track disclim = Disciplinary climate sector = 1 = Catholic, 0 = public size =school enrollment C.J. Anderson (Illinois) Random Intercept Models Spring / 80

72 HLM for Lots of Macro-level Level 1: (math) ij = β 0j +β 1j (SES ij SES j )+β 2j (female) ij +β 3j (minority) ij +R ij where R ij N(0,σ 2 ) and independent. Level 2: β 0j = γ 00 +γ 01 (SES) j +γ 02 (himinty) j +γ 03 (pracad) j β 1j = γ 10 β 2j = γ 20 β 3j = γ 30 +γ 04 (disclim) j +γ 05 (sector) j +γ 06 (size) j +U 0j where U 0j N(0,τ0 2 ) and independent, and R ij and U j are independent. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

73 Linear Mixed w/ Lots of Macro-level (math) ij = γ 00 +γ 10 (SES ij SES j )+γ 20 (female) ij +γ 30 (minority) ij +γ 01 (SES) j +γ 02 (himinty) j +γ 03 (pracad) j +γ 04 (disclim) j +γ 05 (sector) j +γ 06 (size) j +U 0j +R ij What s the marginal model? C.J. Anderson (Illinois) Random Intercept Models Spring / 80

74 Edited SAS/MIXED output The Mixed Procedure Dimensions Covariance Parameters 2 Columns in X 13 Columns in Z Per Subject 1 Subjects 160 Max Obs Per Subject 67 Observations Used 7185 Observations Not Used 0 Total Observations 7185 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

75 Edited SAS/MIXED output Convergence criteria met. Covariance Parameter Estimates Standard Z Cov Parm Subject Estimate Error Value Pr Z UN(1,1) id <.0001 Residual <.0001 C.J. Anderson (Illinois) Random Intercept Models Spring / 80

76 Edited SAS/MIXED output: Fixed Effects Student student Sector Std Effect ethnicity gender Est. Error Intercept cses minority not minority minority 0. female male female female 0. meanses himinty pracad disclim sector public sector Catholic 0. size C.J. Anderson (Illinois) Random Intercept Models Spring / 80

77 Edited SAS/MIXED output Type 3 Tests of Fixed Effects Num Den Effect DF DF F Value Pr > F cses <.0001 minority <.0001 female <.0001 meanses <.0001 himinty pracad disclim sector size C.J. Anderson (Illinois) Random Intercept Models Spring / 80

78 SES j = n j i=1 (SES) ij C.J. Anderson (Illinois) Random Intercept Models Spring / 80 Simple Model Contrast ANCOVA & HLM Empty Model 1 Explanatory Multiple Explanatory Variables Summary Summary & Comparison: Fixed Effects Add cses ij Add all All micro Null Model & (SES) j mirco level and macro Value SE Value SE Value SE Value SE intercept centered SES male not minority mean SES himinty pracd disclim sector size Note: cses ij = (SES) ij (SES) j

79 Summary & Comparison: Random Add cses ij Add all All micro Null Model & (SES) j mirco level and macro Value SE Value SE Value SE Value SE Random effects τ0 2 (between) σ 2 (within) Note: cses ij = (SES) ij (SES) j SES j = n j i=1 (SES) ij C.J. Anderson (Illinois) Random Intercept Models Spring / 80

80 Summary: Random Intercept Models Concepts covered: Within group dependency accounted for by random effect (i.e., R ij ). Between group differences accounted for by random intercept (i.e., U 0j ). Central role of variance between and within groups. Effect of adding Level 1 and Level 2 predictors. Mean centering of level 1 predictors and adding the mean back in at Level 2. Intra-class correlation or ICC. HLMs with only random intercepts imply homoscedasticity. C.J. Anderson (Illinois) Random Intercept Models Spring / 80

Models for Clustered Data

Models for Clustered Data Models for Clustered Data Edps/Psych/Soc 589 Carolyn J Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Spring 2019 Outline Notation NELS88 data Fixed Effects ANOVA

More information

Models for Clustered Data

Models for Clustered Data Models for Clustered Data Edps/Psych/Stat 587 Carolyn J Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Fall 2017 Outline Notation NELS88 data Fixed Effects ANOVA

More information

Hierarchical Linear Models (HLM) Using R Package nlme. Interpretation. 2 = ( x 2) u 0j. e ij

Hierarchical Linear Models (HLM) Using R Package nlme. Interpretation. 2 = ( x 2) u 0j. e ij Hierarchical Linear Models (HLM) Using R Package nlme Interpretation I. The Null Model Level 1 (student level) model is mathach ij = β 0j + e ij Level 2 (school level) model is β 0j = γ 00 + u 0j Combined

More information

Subject-specific observed profiles of log(fev1) vs age First 50 subjects in Six Cities Study

Subject-specific observed profiles of log(fev1) vs age First 50 subjects in Six Cities Study Subject-specific observed profiles of log(fev1) vs age First 50 subjects in Six Cities Study 1.4 0.0-6 7 8 9 10 11 12 13 14 15 16 17 18 19 age Model 1: A simple broken stick model with knot at 14 fit with

More information

Random Effects. Edps/Psych/Stat 587. Carolyn J. Anderson. Fall Department of Educational Psychology. c Board of Trustees, University of Illinois

Random Effects. Edps/Psych/Stat 587. Carolyn J. Anderson. Fall Department of Educational Psychology. c Board of Trustees, University of Illinois Random Effects Edps/Psych/Stat 587 Carolyn J. Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Fall 2017 Outline Introduction Empirical Bayes inference Henderson

More information

Serial Correlation. Edps/Psych/Stat 587. Carolyn J. Anderson. Fall Department of Educational Psychology

Serial Correlation. Edps/Psych/Stat 587. Carolyn J. Anderson. Fall Department of Educational Psychology Serial Correlation Edps/Psych/Stat 587 Carolyn J. Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Fall 017 Model for Level 1 Residuals There are three sources

More information

Random Effects. Edps/Psych/Stat 587. Carolyn J. Anderson. Fall Department of Educational Psychology. university of illinois at urbana-champaign

Random Effects. Edps/Psych/Stat 587. Carolyn J. Anderson. Fall Department of Educational Psychology. university of illinois at urbana-champaign Random Effects Edps/Psych/Stat 587 Carolyn J. Anderson Department of Educational Psychology I L L I N O I S university of illinois at urbana-champaign Fall 2012 Outline Introduction Empirical Bayes inference

More information

Estimation: Problems & Solutions

Estimation: Problems & Solutions Estimation: Problems & Solutions Edps/Psych/Soc 587 Carolyn J. Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Spring 2019 Outline 1. Introduction: Estimation

More information

Estimation: Problems & Solutions

Estimation: Problems & Solutions Estimation: Problems & Solutions Edps/Psych/Stat 587 Carolyn J. Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Fall 2017 Outline 1. Introduction: Estimation of

More information

Statistical Inference: The Marginal Model

Statistical Inference: The Marginal Model Statistical Inference: The Marginal Model Edps/Psych/Stat 587 Carolyn J. Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Fall 2017 Outline Inference for fixed

More information

Random Coefficient Model (a.k.a. multilevel model) (Adapted from UCLA Statistical Computing Seminars)

Random Coefficient Model (a.k.a. multilevel model) (Adapted from UCLA Statistical Computing Seminars) STAT:5201 Applied Statistic II Random Coefficient Model (a.k.a. multilevel model) (Adapted from UCLA Statistical Computing Seminars) School math achievement scores The data file consists of 7185 students

More information

SAS Syntax and Output for Data Manipulation: CLDP 944 Example 3a page 1

SAS Syntax and Output for Data Manipulation: CLDP 944 Example 3a page 1 CLDP 944 Example 3a page 1 From Between-Person to Within-Person Models for Longitudinal Data The models for this example come from Hoffman (2015) chapter 3 example 3a. We will be examining the extent to

More information

Ron Heck, Fall Week 3: Notes Building a Two-Level Model

Ron Heck, Fall Week 3: Notes Building a Two-Level Model Ron Heck, Fall 2011 1 EDEP 768E: Seminar on Multilevel Modeling rev. 9/6/2011@11:27pm Week 3: Notes Building a Two-Level Model We will build a model to explain student math achievement using student-level

More information

Designing Multilevel Models Using SPSS 11.5 Mixed Model. John Painter, Ph.D.

Designing Multilevel Models Using SPSS 11.5 Mixed Model. John Painter, Ph.D. Designing Multilevel Models Using SPSS 11.5 Mixed Model John Painter, Ph.D. Jordan Institute for Families School of Social Work University of North Carolina at Chapel Hill 1 Creating Multilevel Models

More information

Longitudinal Data Analysis via Linear Mixed Model

Longitudinal Data Analysis via Linear Mixed Model Longitudinal Data Analysis via Linear Mixed Model Edps/Psych/Stat 587 Carolyn J. Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Fall 2017 Outline Introduction

More information

Stat 209 Lab: Linear Mixed Models in R This lab covers the Linear Mixed Models tutorial by John Fox. Lab prepared by Karen Kapur. ɛ i Normal(0, σ 2 )

Stat 209 Lab: Linear Mixed Models in R This lab covers the Linear Mixed Models tutorial by John Fox. Lab prepared by Karen Kapur. ɛ i Normal(0, σ 2 ) Lab 2 STAT209 1/31/13 A complication in doing all this is that the package nlme (lme) is supplanted by the new and improved lme4 (lmer); both are widely used so I try to do both tracks in separate Rogosa

More information

Introduction to the Analysis of Hierarchical and Longitudinal Data

Introduction to the Analysis of Hierarchical and Longitudinal Data Introduction to the Analysis of Hierarchical and Longitudinal Data Georges Monette, York University with Ye Sun SPIDA June 7, 2004 1 Graphical overview of selected concepts Nature of hierarchical models

More information

36-309/749 Experimental Design for Behavioral and Social Sciences. Dec 1, 2015 Lecture 11: Mixed Models (HLMs)

36-309/749 Experimental Design for Behavioral and Social Sciences. Dec 1, 2015 Lecture 11: Mixed Models (HLMs) 36-309/749 Experimental Design for Behavioral and Social Sciences Dec 1, 2015 Lecture 11: Mixed Models (HLMs) Independent Errors Assumption An error is the deviation of an individual observed outcome (DV)

More information

Topic 17 - Single Factor Analysis of Variance. Outline. One-way ANOVA. The Data / Notation. One way ANOVA Cell means model Factor effects model

Topic 17 - Single Factor Analysis of Variance. Outline. One-way ANOVA. The Data / Notation. One way ANOVA Cell means model Factor effects model Topic 17 - Single Factor Analysis of Variance - Fall 2013 One way ANOVA Cell means model Factor effects model Outline Topic 17 2 One-way ANOVA Response variable Y is continuous Explanatory variable is

More information

SAS Syntax and Output for Data Manipulation:

SAS Syntax and Output for Data Manipulation: CLP 944 Example 5 page 1 Practice with Fixed and Random Effects of Time in Modeling Within-Person Change The models for this example come from Hoffman (2015) chapter 5. We will be examining the extent

More information

Variance component models part I

Variance component models part I Faculty of Health Sciences Variance component models part I Analysis of repeated measurements, 30th November 2012 Julie Lyng Forman & Lene Theil Skovgaard Department of Biostatistics, University of Copenhagen

More information

Hierarchical Generalized Linear Models. ERSH 8990 REMS Seminar on HLM Last Lecture!

Hierarchical Generalized Linear Models. ERSH 8990 REMS Seminar on HLM Last Lecture! Hierarchical Generalized Linear Models ERSH 8990 REMS Seminar on HLM Last Lecture! Hierarchical Generalized Linear Models Introduction to generalized models Models for binary outcomes Interpreting parameter

More information

Introduction to Within-Person Analysis and RM ANOVA

Introduction to Within-Person Analysis and RM ANOVA Introduction to Within-Person Analysis and RM ANOVA Today s Class: From between-person to within-person ANOVAs for longitudinal data Variance model comparisons using 2 LL CLP 944: Lecture 3 1 The Two Sides

More information

UNIVERSITY OF TORONTO. Faculty of Arts and Science APRIL 2010 EXAMINATIONS STA 303 H1S / STA 1002 HS. Duration - 3 hours. Aids Allowed: Calculator

UNIVERSITY OF TORONTO. Faculty of Arts and Science APRIL 2010 EXAMINATIONS STA 303 H1S / STA 1002 HS. Duration - 3 hours. Aids Allowed: Calculator UNIVERSITY OF TORONTO Faculty of Arts and Science APRIL 2010 EXAMINATIONS STA 303 H1S / STA 1002 HS Duration - 3 hours Aids Allowed: Calculator LAST NAME: FIRST NAME: STUDENT NUMBER: There are 27 pages

More information

Introduction and Background to Multilevel Analysis

Introduction and Background to Multilevel Analysis Introduction and Background to Multilevel Analysis Dr. J. Kyle Roberts Southern Methodist University Simmons School of Education and Human Development Department of Teaching and Learning Background and

More information

Additional Notes: Investigating a Random Slope. When we have fixed level-1 predictors at level 2 we show them like this:

Additional Notes: Investigating a Random Slope. When we have fixed level-1 predictors at level 2 we show them like this: Ron Heck, Summer 01 Seminars 1 Multilevel Regression Models and Their Applications Seminar Additional Notes: Investigating a Random Slope We can begin with Model 3 and add a Random slope parameter. If

More information

1. (Rao example 11.15) A study measures oxygen demand (y) (on a log scale) and five explanatory variables (see below). Data are available as

1. (Rao example 11.15) A study measures oxygen demand (y) (on a log scale) and five explanatory variables (see below). Data are available as ST 51, Summer, Dr. Jason A. Osborne Homework assignment # - Solutions 1. (Rao example 11.15) A study measures oxygen demand (y) (on a log scale) and five explanatory variables (see below). Data are available

More information

Introducing Generalized Linear Models: Logistic Regression

Introducing Generalized Linear Models: Logistic Regression Ron Heck, Summer 2012 Seminars 1 Multilevel Regression Models and Their Applications Seminar Introducing Generalized Linear Models: Logistic Regression The generalized linear model (GLM) represents and

More information

over Time line for the means). Specifically, & covariances) just a fixed variance instead. PROC MIXED: to 1000 is default) list models with TYPE=VC */

over Time line for the means). Specifically, & covariances) just a fixed variance instead. PROC MIXED: to 1000 is default) list models with TYPE=VC */ CLP 944 Example 4 page 1 Within-Personn Fluctuation in Symptom Severity over Time These data come from a study of weekly fluctuation in psoriasis severity. There was no intervention and no real reason

More information

Class Notes: Week 8. Probit versus Logit Link Functions and Count Data

Class Notes: Week 8. Probit versus Logit Link Functions and Count Data Ronald Heck Class Notes: Week 8 1 Class Notes: Week 8 Probit versus Logit Link Functions and Count Data This week we ll take up a couple of issues. The first is working with a probit link function. While

More information

Ron Heck, Fall Week 8: Introducing Generalized Linear Models: Logistic Regression 1 (Replaces prior revision dated October 20, 2011)

Ron Heck, Fall Week 8: Introducing Generalized Linear Models: Logistic Regression 1 (Replaces prior revision dated October 20, 2011) Ron Heck, Fall 2011 1 EDEP 768E: Seminar in Multilevel Modeling rev. January 3, 2012 (see footnote) Week 8: Introducing Generalized Linear Models: Logistic Regression 1 (Replaces prior revision dated October

More information

Model Estimation Example

Model Estimation Example Ronald H. Heck 1 EDEP 606: Multivariate Methods (S2013) April 7, 2013 Model Estimation Example As we have moved through the course this semester, we have encountered the concept of model estimation. Discussions

More information

A (Brief) Introduction to Crossed Random Effects Models for Repeated Measures Data

A (Brief) Introduction to Crossed Random Effects Models for Repeated Measures Data A (Brief) Introduction to Crossed Random Effects Models for Repeated Measures Data Today s Class: Review of concepts in multivariate data Introduction to random intercepts Crossed random effects models

More information

Estimation and Centering

Estimation and Centering Estimation and Centering PSYED 3486 Feifei Ye University of Pittsburgh Main Topics Estimating the level-1 coefficients for a particular unit Reading: R&B, Chapter 3 (p85-94) Centering-Location of X Reading

More information

Simple, Marginal, and Interaction Effects in General Linear Models: Part 1

Simple, Marginal, and Interaction Effects in General Linear Models: Part 1 Simple, Marginal, and Interaction Effects in General Linear Models: Part 1 PSYC 943 (930): Fundamentals of Multivariate Modeling Lecture 2: August 24, 2012 PSYC 943: Lecture 2 Today s Class Centering and

More information

An Introduction to Mplus and Path Analysis

An Introduction to Mplus and Path Analysis An Introduction to Mplus and Path Analysis PSYC 943: Fundamentals of Multivariate Modeling Lecture 10: October 30, 2013 PSYC 943: Lecture 10 Today s Lecture Path analysis starting with multivariate regression

More information

Introduction to SAS proc mixed

Introduction to SAS proc mixed Faculty of Health Sciences Introduction to SAS proc mixed Analysis of repeated measurements, 2017 Julie Forman Department of Biostatistics, University of Copenhagen Outline Data in wide and long format

More information

Introduction to SAS proc mixed

Introduction to SAS proc mixed Faculty of Health Sciences Introduction to SAS proc mixed Analysis of repeated measurements, 2017 Julie Forman Department of Biostatistics, University of Copenhagen 2 / 28 Preparing data for analysis The

More information

Answers to Problem Set #4

Answers to Problem Set #4 Answers to Problem Set #4 Problems. Suppose that, from a sample of 63 observations, the least squares estimates and the corresponding estimated variance covariance matrix are given by: bβ bβ 2 bβ 3 = 2

More information

Covariance Structure Approach to Within-Cases

Covariance Structure Approach to Within-Cases Covariance Structure Approach to Within-Cases Remember how the data file grapefruit1.data looks: Store sales1 sales2 sales3 1 62.1 61.3 60.8 2 58.2 57.9 55.1 3 51.6 49.2 46.2 4 53.7 51.5 48.3 5 61.4 58.7

More information

STAT3401: Advanced data analysis Week 10: Models for Clustered Longitudinal Data

STAT3401: Advanced data analysis Week 10: Models for Clustered Longitudinal Data STAT3401: Advanced data analysis Week 10: Models for Clustered Longitudinal Data Berwin Turlach School of Mathematics and Statistics Berwin.Turlach@gmail.com The University of Western Australia Models

More information

This is a Randomized Block Design (RBD) with a single factor treatment arrangement (2 levels) which are fixed.

This is a Randomized Block Design (RBD) with a single factor treatment arrangement (2 levels) which are fixed. EXST3201 Chapter 13c Geaghan Fall 2005: Page 1 Linear Models Y ij = µ + βi + τ j + βτij + εijk This is a Randomized Block Design (RBD) with a single factor treatment arrangement (2 levels) which are fixed.

More information

Statistical Methods III Statistics 212. Problem Set 2 - Answer Key

Statistical Methods III Statistics 212. Problem Set 2 - Answer Key Statistical Methods III Statistics 212 Problem Set 2 - Answer Key 1. (Analysis to be turned in and discussed on Tuesday, April 24th) The data for this problem are taken from long-term followup of 1423

More information

An Introduction to Multilevel Models. PSYC 943 (930): Fundamentals of Multivariate Modeling Lecture 25: December 7, 2012

An Introduction to Multilevel Models. PSYC 943 (930): Fundamentals of Multivariate Modeling Lecture 25: December 7, 2012 An Introduction to Multilevel Models PSYC 943 (930): Fundamentals of Multivariate Modeling Lecture 25: December 7, 2012 Today s Class Concepts in Longitudinal Modeling Between-Person vs. +Within-Person

More information

Simple Linear Regression

Simple Linear Regression Simple Linear Regression EdPsych 580 C.J. Anderson Fall 2005 Simple Linear Regression p. 1/80 Outline 1. What it is and why it s useful 2. How 3. Statistical Inference 4. Examining assumptions (diagnostics)

More information

Topic 23: Diagnostics and Remedies

Topic 23: Diagnostics and Remedies Topic 23: Diagnostics and Remedies Outline Diagnostics residual checks ANOVA remedial measures Diagnostics Overview We will take the diagnostics and remedial measures that we learned for regression and

More information

STA 303 H1S / 1002 HS Winter 2011 Test March 7, ab 1cde 2abcde 2fghij 3

STA 303 H1S / 1002 HS Winter 2011 Test March 7, ab 1cde 2abcde 2fghij 3 STA 303 H1S / 1002 HS Winter 2011 Test March 7, 2011 LAST NAME: FIRST NAME: STUDENT NUMBER: ENROLLED IN: (circle one) STA 303 STA 1002 INSTRUCTIONS: Time: 90 minutes Aids allowed: calculator. Some formulae

More information

Longitudinal Data Analysis Using Stata Paul D. Allison, Ph.D. Upcoming Seminar: May 18-19, 2017, Chicago, Illinois

Longitudinal Data Analysis Using Stata Paul D. Allison, Ph.D. Upcoming Seminar: May 18-19, 2017, Chicago, Illinois Longitudinal Data Analysis Using Stata Paul D. Allison, Ph.D. Upcoming Seminar: May 18-19, 217, Chicago, Illinois Outline 1. Opportunities and challenges of panel data. a. Data requirements b. Control

More information

General Linear Model (Chapter 4)

General Linear Model (Chapter 4) General Linear Model (Chapter 4) Outcome variable is considered continuous Simple linear regression Scatterplots OLS is BLUE under basic assumptions MSE estimates residual variance testing regression coefficients

More information

Review of CLDP 944: Multilevel Models for Longitudinal Data

Review of CLDP 944: Multilevel Models for Longitudinal Data Review of CLDP 944: Multilevel Models for Longitudinal Data Topics: Review of general MLM concepts and terminology Model comparisons and significance testing Fixed and random effects of time Significance

More information

REVIEW 8/2/2017 陈芳华东师大英语系

REVIEW 8/2/2017 陈芳华东师大英语系 REVIEW Hypothesis testing starts with a null hypothesis and a null distribution. We compare what we have to the null distribution, if the result is too extreme to belong to the null distribution (p

More information

An Introduction to Path Analysis

An Introduction to Path Analysis An Introduction to Path Analysis PRE 905: Multivariate Analysis Lecture 10: April 15, 2014 PRE 905: Lecture 10 Path Analysis Today s Lecture Path analysis starting with multivariate regression then arriving

More information

Activity #12: More regression topics: LOWESS; polynomial, nonlinear, robust, quantile; ANOVA as regression

Activity #12: More regression topics: LOWESS; polynomial, nonlinear, robust, quantile; ANOVA as regression Activity #12: More regression topics: LOWESS; polynomial, nonlinear, robust, quantile; ANOVA as regression Scenario: 31 counts (over a 30-second period) were recorded from a Geiger counter at a nuclear

More information

Lecture (chapter 13): Association between variables measured at the interval-ratio level

Lecture (chapter 13): Association between variables measured at the interval-ratio level Lecture (chapter 13): Association between variables measured at the interval-ratio level Ernesto F. L. Amaral April 9 11, 2018 Advanced Methods of Social Research (SOCI 420) Source: Healey, Joseph F. 2015.

More information

De-mystifying random effects models

De-mystifying random effects models De-mystifying random effects models Peter J Diggle Lecture 4, Leahurst, October 2012 Linear regression input variable x factor, covariate, explanatory variable,... output variable y response, end-point,

More information

In Class Review Exercises Vartanian: SW 540

In Class Review Exercises Vartanian: SW 540 In Class Review Exercises Vartanian: SW 540 1. Given the following output from an OLS model looking at income, what is the slope and intercept for those who are black and those who are not black? b SE

More information

SAS Code for Data Manipulation: SPSS Code for Data Manipulation: STATA Code for Data Manipulation: Psyc 945 Example 1 page 1

SAS Code for Data Manipulation: SPSS Code for Data Manipulation: STATA Code for Data Manipulation: Psyc 945 Example 1 page 1 Psyc 945 Example page Example : Unconditional Models for Change in Number Match 3 Response Time (complete data, syntax, and output available for SAS, SPSS, and STATA electronically) These data come from

More information

Analysis of Longitudinal Data: Comparison Between PROC GLM and PROC MIXED. Maribeth Johnson Medical College of Georgia Augusta, GA

Analysis of Longitudinal Data: Comparison Between PROC GLM and PROC MIXED. Maribeth Johnson Medical College of Georgia Augusta, GA Analysis of Longitudinal Data: Comparison Between PROC GLM and PROC MIXED Maribeth Johnson Medical College of Georgia Augusta, GA Overview Introduction to longitudinal data Describe the data for examples

More information

MULTILEVEL MODELS. Multilevel-analysis in SPSS - step by step

MULTILEVEL MODELS. Multilevel-analysis in SPSS - step by step MULTILEVEL MODELS Multilevel-analysis in SPSS - step by step Dimitri Mortelmans Centre for Longitudinal and Life Course Studies (CLLS) University of Antwerp Overview of a strategy. Data preparation (centering

More information

The Application and Promise of Hierarchical Linear Modeling (HLM) in Studying First-Year Student Programs

The Application and Promise of Hierarchical Linear Modeling (HLM) in Studying First-Year Student Programs The Application and Promise of Hierarchical Linear Modeling (HLM) in Studying First-Year Student Programs Chad S. Briggs, Kathie Lorentz & Eric Davis Education & Outreach University Housing Southern Illinois

More information

Ann Lazar

Ann Lazar Ann Lazar ann.lazar@ucsf.edu Department of Preventive and Restorative Dental Sciences Department of Epidemiology and Biostatistics University of California, San Francisco February 21, 2014 Motivation Rheumatoid

More information

Lecture 4. Random Effects in Completely Randomized Design

Lecture 4. Random Effects in Completely Randomized Design Lecture 4. Random Effects in Completely Randomized Design Montgomery: 3.9, 13.1 and 13.7 1 Lecture 4 Page 1 Random Effects vs Fixed Effects Consider factor with numerous possible levels Want to draw inference

More information

Econometrics Review questions for exam

Econometrics Review questions for exam Econometrics Review questions for exam Nathaniel Higgins nhiggins@jhu.edu, 1. Suppose you have a model: y = β 0 x 1 + u You propose the model above and then estimate the model using OLS to obtain: ŷ =

More information

Answer to exercise: Blood pressure lowering drugs

Answer to exercise: Blood pressure lowering drugs Answer to exercise: Blood pressure lowering drugs The data set bloodpressure.txt contains data from a cross-over trial, involving three different formulations of a drug for lowering of blood pressure:

More information

Assessing the relation between language comprehension and performance in general chemistry. Appendices

Assessing the relation between language comprehension and performance in general chemistry. Appendices Assessing the relation between language comprehension and performance in general chemistry Daniel T. Pyburn a, Samuel Pazicni* a, Victor A. Benassi b, and Elizabeth E. Tappin c a Department of Chemistry,

More information

Longitudinal Data Analysis Using SAS Paul D. Allison, Ph.D. Upcoming Seminar: October 13-14, 2017, Boston, Massachusetts

Longitudinal Data Analysis Using SAS Paul D. Allison, Ph.D. Upcoming Seminar: October 13-14, 2017, Boston, Massachusetts Longitudinal Data Analysis Using SAS Paul D. Allison, Ph.D. Upcoming Seminar: October 13-14, 217, Boston, Massachusetts Outline 1. Opportunities and challenges of panel data. a. Data requirements b. Control

More information

MATH ASSIGNMENT 2: SOLUTIONS

MATH ASSIGNMENT 2: SOLUTIONS MATH 204 - ASSIGNMENT 2: SOLUTIONS (a) Fitting the simple linear regression model to each of the variables in turn yields the following results: we look at t-tests for the individual coefficients, and

More information

STAT 5200 Handout #23. Repeated Measures Example (Ch. 16)

STAT 5200 Handout #23. Repeated Measures Example (Ch. 16) Motivating Example: Glucose STAT 500 Handout #3 Repeated Measures Example (Ch. 16) An experiment is conducted to evaluate the effects of three diets on the serum glucose levels of human subjects. Twelve

More information

Sample Geometry. Edps/Soc 584, Psych 594. Carolyn J. Anderson

Sample Geometry. Edps/Soc 584, Psych 594. Carolyn J. Anderson Sample Geometry Edps/Soc 584, Psych 594 Carolyn J. Anderson Department of Educational Psychology I L L I N O I S university of illinois at urbana-champaign c Board of Trustees, University of Illinois Spring

More information

Estimating a Piecewise Growth Model with Longitudinal Data that Contains Individual Mobility across Clusters

Estimating a Piecewise Growth Model with Longitudinal Data that Contains Individual Mobility across Clusters Estimating a Piecewise Growth Model with Longitudinal Data that Contains Individual Mobility across Clusters Audrey J. Leroux Georgia State University Piecewise Growth Model (PGM) PGMs are beneficial for

More information

A Re-Introduction to General Linear Models (GLM)

A Re-Introduction to General Linear Models (GLM) A Re-Introduction to General Linear Models (GLM) Today s Class: You do know the GLM Estimation (where the numbers in the output come from): From least squares to restricted maximum likelihood (REML) Reviewing

More information

Lab 11. Multilevel Models. Description of Data

Lab 11. Multilevel Models. Description of Data Lab 11 Multilevel Models Henian Chen, M.D., Ph.D. Description of Data MULTILEVEL.TXT is clustered data for 386 women distributed across 40 groups. ID: 386 women, id from 1 to 386, individual level (level

More information

Introduction to Random Effects of Time and Model Estimation

Introduction to Random Effects of Time and Model Estimation Introduction to Random Effects of Time and Model Estimation Today s Class: The Big Picture Multilevel model notation Fixed vs. random effects of time Random intercept vs. random slope models How MLM =

More information

Contrasting Marginal and Mixed Effects Models Recall: two approaches to handling dependence in Generalized Linear Models:

Contrasting Marginal and Mixed Effects Models Recall: two approaches to handling dependence in Generalized Linear Models: Contrasting Marginal and Mixed Effects Models Recall: two approaches to handling dependence in Generalized Linear Models: Marginal models: based on the consequences of dependence on estimating model parameters.

More information

Multilevel/Mixed Models and Longitudinal Analysis Using Stata

Multilevel/Mixed Models and Longitudinal Analysis Using Stata Multilevel/Mixed Models and Longitudinal Analysis Using Stata Isaac J. Washburn PhD Research Associate Oregon Social Learning Center Summer Workshop Series July 2010 Longitudinal Analysis 1 Longitudinal

More information

Topic 25 - One-Way Random Effects Models. Outline. Random Effects vs Fixed Effects. Data for One-way Random Effects Model. One-way Random effects

Topic 25 - One-Way Random Effects Models. Outline. Random Effects vs Fixed Effects. Data for One-way Random Effects Model. One-way Random effects Topic 5 - One-Way Random Effects Models One-way Random effects Outline Model Variance component estimation - Fall 013 Confidence intervals Topic 5 Random Effects vs Fixed Effects Consider factor with numerous

More information

Ordinary Least Squares Regression Explained: Vartanian

Ordinary Least Squares Regression Explained: Vartanian Ordinary Least Squares Regression Explained: Vartanian When to Use Ordinary Least Squares Regression Analysis A. Variable types. When you have an interval/ratio scale dependent variable.. When your independent

More information

Ordinal Variables in 2 way Tables

Ordinal Variables in 2 way Tables Ordinal Variables in 2 way Tables Edps/Psych/Soc 589 Carolyn J. Anderson Department of Educational Psychology c Board of Trustees, University of Illinois Fall 2018 C.J. Anderson (Illinois) Ordinal Variables

More information

HLM Models and Type VI Errors

HLM Models and Type VI Errors Models and Type VI Errors Understanding Models and Type VI Errors: The Need for Reflection Susan M. Tracz Isadore Newman David O. Newman California State University, Fresno Florida International University

More information

MIXED MODELS FOR REPEATED (LONGITUDINAL) DATA PART 2 DAVID C. HOWELL 4/1/2010

MIXED MODELS FOR REPEATED (LONGITUDINAL) DATA PART 2 DAVID C. HOWELL 4/1/2010 MIXED MODELS FOR REPEATED (LONGITUDINAL) DATA PART 2 DAVID C. HOWELL 4/1/2010 Part 1 of this document can be found at http://www.uvm.edu/~dhowell/methods/supplements/mixed Models for Repeated Measures1.pdf

More information

Step 2: Select Analyze, Mixed Models, and Linear.

Step 2: Select Analyze, Mixed Models, and Linear. Example 1a. 20 employees were given a mood questionnaire on Monday, Wednesday and again on Friday. The data will be first be analyzed using a Covariance Pattern model. Step 1: Copy Example1.sav data file

More information

36-402/608 Homework #10 Solutions 4/1

36-402/608 Homework #10 Solutions 4/1 36-402/608 Homework #10 Solutions 4/1 1. Fixing Breakout 17 (60 points) You must use SAS for this problem! Modify the code in wallaby.sas to load the wallaby data and to create a new outcome in the form

More information

Analysis of variance and regression. May 13, 2008

Analysis of variance and regression. May 13, 2008 Analysis of variance and regression May 13, 2008 Repeated measurements over time Presentation of data Traditional ways of analysis Variance component model (the dogs revisited) Random regression Baseline

More information

STAT 512 MidTerm I (2/21/2013) Spring 2013 INSTRUCTIONS

STAT 512 MidTerm I (2/21/2013) Spring 2013 INSTRUCTIONS STAT 512 MidTerm I (2/21/2013) Spring 2013 Name: Key INSTRUCTIONS 1. This exam is open book/open notes. All papers (but no electronic devices except for calculators) are allowed. 2. There are 5 pages in

More information

SPIDA 2012 Part 2 Mixed Models with R: Hierarchical Models to Mixed Models

SPIDA 2012 Part 2 Mixed Models with R: Hierarchical Models to Mixed Models SPIDA 2012 Part 2 Mixed Models with R: Hierarchical Models to Mixed Models Georges Monette May 2012 Email: georges@yorku.ca http://scs.math.yorku.ca/index.php/spida_2012june 2010 1 Contents The many hierarchies

More information

Statistical Distribution Assumptions of General Linear Models

Statistical Distribution Assumptions of General Linear Models Statistical Distribution Assumptions of General Linear Models Applied Multilevel Models for Cross Sectional Data Lecture 4 ICPSR Summer Workshop University of Colorado Boulder Lecture 4: Statistical Distributions

More information

Variance component models

Variance component models Faculty of Health Sciences Variance component models Analysis of repeated measurements, NFA 2016 Julie Lyng Forman & Lene Theil Skovgaard Department of Biostatistics, University of Copenhagen Topics for

More information

Data Analysis Using R ASC & OIR

Data Analysis Using R ASC & OIR Data Analysis Using R ASC & OIR Overview } What is Statistics and the process of study design } Correlation } Simple Linear Regression } Multiple Linear Regression 2 What is Statistics? Statistics is a

More information

On the Behavior of Marginal and Conditional Akaike Information Criteria in Linear Mixed Models

On the Behavior of Marginal and Conditional Akaike Information Criteria in Linear Mixed Models On the Behavior of Marginal and Conditional Akaike Information Criteria in Linear Mixed Models Thomas Kneib Department of Mathematics Carl von Ossietzky University Oldenburg Sonja Greven Department of

More information

Correlation and Linear Regression

Correlation and Linear Regression Correlation and Linear Regression Correlation: Relationships between Variables So far, nearly all of our discussion of inferential statistics has focused on testing for differences between group means

More information

EPSY 905: Fundamentals of Multivariate Modeling Online Lecture #7

EPSY 905: Fundamentals of Multivariate Modeling Online Lecture #7 Introduction to Generalized Univariate Models: Models for Binary Outcomes EPSY 905: Fundamentals of Multivariate Modeling Online Lecture #7 EPSY 905: Intro to Generalized In This Lecture A short review

More information

Review of the General Linear Model

Review of the General Linear Model Review of the General Linear Model EPSY 905: Multivariate Analysis Online Lecture #2 Learning Objectives Types of distributions: Ø Conditional distributions The General Linear Model Ø Regression Ø Analysis

More information

ANOVA Longitudinal Models for the Practice Effects Data: via GLM

ANOVA Longitudinal Models for the Practice Effects Data: via GLM Psyc 943 Lecture 25 page 1 ANOVA Longitudinal Models for the Practice Effects Data: via GLM Model 1. Saturated Means Model for Session, E-only Variances Model (BP) Variances Model: NO correlation, EQUAL

More information

Odor attraction CRD Page 1

Odor attraction CRD Page 1 Odor attraction CRD Page 1 dm'log;clear;output;clear'; options ps=512 ls=99 nocenter nodate nonumber nolabel FORMCHAR=" ---- + ---+= -/\*"; ODS LISTING; *** Table 23.2 ********************************************;

More information

Econometrics I KS. Module 1: Bivariate Linear Regression. Alexander Ahammer. This version: March 12, 2018

Econometrics I KS. Module 1: Bivariate Linear Regression. Alexander Ahammer. This version: March 12, 2018 Econometrics I KS Module 1: Bivariate Linear Regression Alexander Ahammer Department of Economics Johannes Kepler University of Linz This version: March 12, 2018 Alexander Ahammer (JKU) Module 1: Bivariate

More information

UNIVERSITY OF TORONTO Faculty of Arts and Science

UNIVERSITY OF TORONTO Faculty of Arts and Science UNIVERSITY OF TORONTO Faculty of Arts and Science December 2013 Final Examination STA442H1F/2101HF Methods of Applied Statistics Jerry Brunner Duration - 3 hours Aids: Calculator Model(s): Any calculator

More information

Topic 20: Single Factor Analysis of Variance

Topic 20: Single Factor Analysis of Variance Topic 20: Single Factor Analysis of Variance Outline Single factor Analysis of Variance One set of treatments Cell means model Factor effects model Link to linear regression using indicator explanatory

More information

Lecture 3: Inference in SLR

Lecture 3: Inference in SLR Lecture 3: Inference in SLR STAT 51 Spring 011 Background Reading KNNL:.1.6 3-1 Topic Overview This topic will cover: Review of hypothesis testing Inference about 1 Inference about 0 Confidence Intervals

More information

NELS 88. Latent Response Variable Formulation Versus Probability Curve Formulation

NELS 88. Latent Response Variable Formulation Versus Probability Curve Formulation NELS 88 Table 2.3 Adjusted odds ratios of eighth-grade students in 988 performing below basic levels of reading and mathematics in 988 and dropping out of school, 988 to 990, by basic demographics Variable

More information

Course Introduction and Overview Descriptive Statistics Conceptualizations of Variance Review of the General Linear Model

Course Introduction and Overview Descriptive Statistics Conceptualizations of Variance Review of the General Linear Model Course Introduction and Overview Descriptive Statistics Conceptualizations of Variance Review of the General Linear Model EPSY 905: Multivariate Analysis Lecture 1 20 January 2016 EPSY 905: Lecture 1 -

More information