Modern repeated measures analysis using mixed models in SPSS (2)

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
so far no there are narcy's will considered what's known as fixed parameters that is parameters that have one value in this example we're going to consider parameters that don't just have value but they have a distribution associated with them as well and the situation is normally normally distributed and therefore it has a variance or standard deviation so be estimation as standard deviation as well as the actual parameter value and parameter values that have a distribution as well as one value are called random parameters it doesn't mean they're random it actually means that they have a normal distribution so let's take this example from an excellent book by twists called applied multi-level analysis this comes from an example concerned with repeated measures so here we have a set of four values for each individual so it's showing the first two-and-a-half individuals there and it's a values concerned with health and veg consolute lifestyle and they're taken up four different times for each individual so we're going to consider three different models with in other ways you can model this data in various degrees of complexity the first model consider is in rather inappropriate but you might fall into this trap vandalizing data in this way so I just want to show you the wrong way of analyzing to begin with a very naive way for analyzing its data might be just to think oh well we've got health and lifestyle there and all these times and individuals I said I won't just look at health and lifestyle so you could do that simply by producing a graph a good old-fashioned scatter blocked graph have the two values health lifestyle obviously had a regression line if we wished so there we are doesn't like much is going on there doesn't look very hopeful but of course what we're not considering is that these values are actually four values that are repeated on the same individual so highly unlikely to be independent and also actually a whole load of sets of data here for each individual might very dependent upon the initial health level so we need to take those things into account but first of all we'll carry on with this bad analysis and say oh right let's come out a regression analysis on this so to carry out a simple regression analysis using the mixed models dialog box just go to mixed models linear nor the first box completely then go into here and we know health is a dependent variable and lifestyle is the covariant and with the con fixed and we choose lifestyle so fixed variable it doesn't matter if you choose factorial or main effect to get exactly the same result here and also you don't need to worry about random variables where they're not consider those in this model do need to consider the estimation how we're going to work out the value and I want to use maximum likelihood here because that's the version of the estimation procedure that twits uses and want to get compatible results with him then statistics we just choose parameter estimates here I've chosen all the options we need from here and just click OK so in the output we have first of all the actual SPSS syntax it created then we have a table called dimension table which tells us how many parameters are used for the various parameter estimates so it used a fixed effect parameter estimate for the intercept and a fixed effect from reset for lifestyle they had once residuals versus used three parameters in total and here we have our minus two log likelihood which is analogous to the residual sum of squares not much useful in its own but quite useful one to care pair this poor model was something we might produce later on that hopefully we a lot better and here are the intercept and nice style parameter values fixed parameter values and so we've got 3.8 there and point one four there so for every one unit change in health we have 0.14 unit change in lifestyle and they're both highly significant so we can accept those parameters but remember totally ignoring here in fact that they're repeated measures and they're within individuals for values so we need to consider so now we're going to create a more complex model where we take into account that we have subjects within a repeated measures design so we know ID is equivalent to their subjects that's at first variable if you remember then repeat it measure its defined by its value here time I'm going to choose here an option called scales identity which assumes that each of these times that we take a value time one two four has the same variance and they're independent there's no correlation between them for now so we click continue and we have the same values here as before we don't need to change this they're fixed we still have our lifestyle as fixed variable parameter estimate now we're going to random I do want to change some things here first we want to include the intercept so remember what we're going to do now is actually design a model that takes into account the random possibility in the intercept that depending upon the individual the intercept value will be different and it will follow a normal distribution this is you could say one step up from in a city covariance where we'd have a different value at the intercept for each level of the factor we were considering here we're not considering discrete values we consider an actually a distribution a normal distribution for the intercept values and we're going to also make sure we use this grouping forever the ID now subject ID here so we should have one two random effects variables estimated in their model click continue and we just check got the same estimation yes some likelihood fine a statistics we want to make sure we actually get some output of our covariances that we're asking for and we can see here there's covariances a parameter estimates and covariances or random effects that's what we created these are random effects we want to make sure we get that continue there and okay so now you'll notice it tells us that we've got two covariance structures in our model one variance components which is assuming that there's no correlation between the two that we created our random effects and also an identity matrix here for the bottom level level one between the repeated measures and that will accept the total number parameters we've used up used four parameters here and we can compare that the previous model where we only used three also we've got here minus two log likelihood value eight one two compared to where value there have 1184 so long from three degrees of freedom the four degrees of freedom and the Maxima a massive change in the mice log likelihood if we divide took one value from the other then the degrees of freedom would be one and we do the chi-square value on that cuz we know it fall client registration may find it was very significant point zero zero zero one but I'll leave us an exercise and we get her results here and we got her fixed parameter estimates or the interchange who will intercept there and lifestyle sets for for intercept and point zero seven for lifestyle and pairs two three there and went one for there so it's gone from point one four two point zero seven states dropped slightly the lifestyle and now we have the covariances all the variance values rather for each of our random effects so there's repeated measures and that saying what the appearances the repeated measures and that's for the intercept that's its variance there and how the same as interests with you we can consider this covariance parameter table eight or more because we obtained from it thing called the ICC the inter class correlation coefficient tells us how much variability is taken into account by us grouping the values together into patient category size so if we take the total variance value it's point one two seven plus 0.03 to add that together and then put on the top the actual between patient variance which is our intercept variance which is point three two we get a the inter-class correlation value which is around point seven and that shows that 70% of the variability is actually due to our patient categories so we considered a model where we got a random intercept but what about random slope as well so that's the next stage to model so go back to our model and this time we just need to change one other thing in the random so we go back to random here and we actually include lifestyle as well as a novel random effect so now we have an interceptor and an effect lifestyle and an effect and the ID the patient random effect but we also want to get correlation between them so to do that we actually have to choose here and structures we're choosing an unstructured covariance matrix click continue and also just check statistics again and we got the covariance it's a random effects and the fact we're estimates so you continue okay and this time get a warning so as a bit of a problem with determination to try and find the actual values but we'll still look at them so we're here we have an unstructured covariance matrix the random effects of intercept and lifestyle as I said what two fixed effects intercepts and light style and then we've got the repeated fix there again another random effect jujin identity and this time I've got a minus two log likelihood of 817 which compares to our previous value up here of 812 so it looks like it hasn't done much in terms of improving the model continue for now and we see we've got an intercept value of four point zero five and a start point zero six six four point zero five and two point zero six six four point five point zero seven there's no difference there and then we look now at random parameters covariance parameters here and we can see we've got now a matrix in effect we've got row 1 column 1 Row 2 column 1 Row 2 column 2 and it's actually Prudential because I asked for co-variants table it's done it for us they're morons easy way to say just look at the first value here first of all repeated-measures that's basically the bottom level level one error variance that's point zero point one one five and then we've got here the intercept and the lifestyle so we've got a variance value for the intercept now and a variance value for the slope and the covariance between them correlation that is you can think of between the two so this table can be quite confusing but let's make sure you understand this we've got here the intercept variability parameter estimate which one nine two then we've got lifestyle and inter intercept which is really our slope parameter lifestyle so we've got here is a minus point one seven that's saying that as lifestyle increases the lines get less steep as it were instead of fanning out they fan closer together and here we have this as the variance just on its own for slope the other issue we need to consider is is this model with both a random intercept and a random slope better than just having a random intercept and we do that just by coming up with like the ratio test so we take our degrees of freedom there which is six compared with the previous one which is four that's 6 minus 4 is 2 so it got a chi-square just need two degrees of freedom and then we take this value there eight twelve point over is six and take that value away from 8:17 0.807 and we'll find actually that's it's not silly at all it's something like 0.12 or something so we can actually say we go for the more parsimonious model and we ignore the random slope and just go for the model with the random intercept question is how do you interpret these values these fixed effect values with a random intercept well twisted very good he explains that you can actually interpret this lifestyle estimate value two ways and you can interpret in the between patient interpretation and within patient interpretation so a treating patients interpretation is compatible with the normal way you interpret it so that is two patients differ and one unit of the lifestyle indicator then they differ by 0.2 0.8 ER the second way we can interpret it is concerned with the fact that they are repeated measures so that when health increases by one unit of a particular time period were patient change is accompanied by an increase of point zero seven units of health for that patient if we considered repeated measures and the problem is that this regression coefficient here is point zero seven zero is partly between patients and partly within patients so it's difficult to say which part of it belongs being on which part belongs between there are ways of doing that with twist talked about which I won't go into now so I hope you enjoyed your first introduction to random effects modeling you
Info
Channel: Robin Beaumont
Views: 123,504
Rating: 4.7985611 out of 5
Keywords: random effects, covariance matrix, unstructured covariance matrix, likelihood ratio test
Id: LKT4brBV-jo
Channel Id: undefined
Length: 16min 9sec (969 seconds)
Published: Tue Mar 29 2011
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.