Search found 1239 matches
- Tue Apr 20, 2021 6:41 pm
- Forum: runmlwin user forum
- Topic: Average Marginal Effects via runmlwin
- Replies: 2
- Views: 18
Re: Average Marginal Effects via runmlwin
My interpretation of this is that he is suggesting that you duplicate each row of your dataset 1000 times (presumably with https://www.stata.com/help.cgi?expand ) so that you have a copy for each MCMC iteration. You would then combine this with the parameter estimates for the corresponding iteration...
- Fri Apr 09, 2021 3:43 pm
- Forum: R2MLwiN user forum
- Topic: Interaction plots for mlwinfitMCMC fixed effects
- Replies: 2
- Views: 135
Re: Interaction plots for mlwinfitMCMC fixed effects
You could manually create the data required for this plot by generating a chain of predictions and then calculating the mean and credible intervals from this. An example of this would be as follows: library(R2MLwiN) library(coda) data(tutorial, package = "R2MLwiN") (model1 <- runMLwiN(normexam ~ 1 +...
- Thu Apr 08, 2021 3:58 pm
- Forum: MLwiN user forum
- Topic: Input columns have unequal length
- Replies: 2
- Views: 123
Re: Input columns have unequal length
I suspect that the command is complaining that your 'CNTSCHID' column is a different length to the others. All the input columns involved in this command need to be of the same length. c1500 is included in the command as this is temporary output column where it will put the short version of the ID c...
- Wed Mar 31, 2021 2:43 pm
- Forum: Realcom user forum
- Topic: Error in Realcom
- Replies: 1
- Views: 1080
Re: Error in Realcom
Have you tried running this with fewer responses? You don't say how many rows you have in your data, or number of categories in each response but it may be that there isn't enough data to support this model.
- Fri Mar 26, 2021 11:10 am
- Forum: MLwiN user forum
- Topic: Unexpanded level 2 id column
- Replies: 2
- Views: 797
Re: Unexpanded level 2 id column
As you are fitting a multivariate model there will already be a level-1 identifier included for the response indicator. When setting up the model you would therefore need to specify three levels, with patient at level-2 and clinic at level-3. MLwiN checks that the identifier variable you set at leve...
- Tue Mar 23, 2021 5:58 pm
- Forum: runmlwin user forum
- Topic: DICs difference when comparing models after MCMC
- Replies: 2
- Views: 694
Re: DICs difference when comparing models after MCMC
Bill gives some guidance on slide 57 of a workshop presentation that he gave some years ago, available at: https://www.ukdataservice.ac.uk/media/307220/presentation4.pdf The MRC Biostatistics unit, who originally developed the BUGS software, also give some suggestions: https://www.mrc-bsu.cam.ac.uk/...
- Tue Mar 23, 2021 2:58 pm
- Forum: runmlwin user forum
- Topic: 95%Credible intervals are smaller than OR
- Replies: 6
- Views: 735
Re: 95%Credible intervals are smaller than OR
You can obtain the MCMC chains as a dataset with the following command: mcmcsum, getchains Once you have this you can use the standard Stata data manipulation commands to process it, i.e. gen , sort and centile . You ought to get the same results as before as this should be equivalent to what runmlw...
- Tue Mar 23, 2021 1:34 pm
- Forum: runmlwin user forum
- Topic: 95%Credible intervals are smaller than OR
- Replies: 6
- Views: 735
Re: 95%Credible intervals are smaller than OR
The way that the credible intervals for this would be calculated is as follows: Fetch the MCMC chain for the parameter Exponentiate the values to convert to odds-ratios Sort the chain Extract the 2.5% and 97.5% quantiles I suppose that if the chain contained a few extreme values then this could resu...
- Mon Mar 22, 2021 2:48 pm
- Forum: runmlwin user forum
- Topic: 95%Credible intervals are smaller than OR
- Replies: 6
- Views: 735
Re: 95%Credible intervals are smaller than OR
That does sound a bit strange. Have you tried plotting the chains? What do the results look like it you don't convert them to odds-ratios?
- Fri Mar 12, 2021 3:29 pm
- Forum: runmlwin user forum
- Topic: using runmlwin with survey weights
- Replies: 3
- Views: 1051
Re: using runmlwin with survey weights
Sorry, there is no change here, and this is not currently in our in our future plans.