## Search found 1275 matches

Fri Mar 26, 2021 11:10 am
Forum: MLwiN user forum
Topic: Unexpanded level 2 id column
Replies: 2
Views: 6739

### 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: 7043

### 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: 8393

### 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: 8393

### 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: 8393

### 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: 7713

### Re: using runmlwin with survey weights

Sorry, there is no change here, and this is not currently in our in our future plans.
Fri Mar 12, 2021 11:39 am
Forum: runmlwin user forum
Topic: Using Stata commands lroc and lstat after runmlwin
Replies: 6
Views: 13342

### Re: Using Stata commands lroc and lstat after runmlwin

I suspect that your problem is that you have forgotten to multiple the fixed-part parameters by their associated data, so you'll want something more like: generate prediction = [FP1]cons*cons + [FP1]male*male + [FP1]agegroup2*agegroup2 + [FP1]agegroup3*agegroup3 + [FP1]agegroup4*agegroup4 + [FP1]age...
Thu Mar 11, 2021 6:21 pm
Forum: runmlwin user forum
Topic: Using Stata commands lroc and lstat after runmlwin
Replies: 6
Views: 13342

### Re: Using Stata commands lroc and lstat after runmlwin

As you have found, running predict after runmlwin will only give you the fixed-part prediction. If you want a prediction with both fixed and random effects then you will need to manually request that the higher-level residuals are returned via the residuals() option and then use these to extend the ...
Thu Mar 11, 2021 1:38 pm
Forum: MLwiN user forum
Topic: Zero-Inflated Negative Binomial?
Replies: 1
Views: 5929

### Re: Zero-Inflated Negative Binomial?

You may find the following post of interest, as it explains the negative-binomial options within MLwiN:
Negative binomial multilevel model
Wed Feb 03, 2021 11:44 am
Forum: MLwiN user forum
Topic: 'invalid stoi argument' - pasting data into MLwiN
Replies: 3
Views: 6713

### Re: 'invalid stoi argument' - pasting data into MLwiN

It's hard to say the exact cause without seeing the data however from the error message it may be that it is interpreting some of the lines of data as MLwiN commands. If this was the case then it might be seeing the first column as the command with subsequent columns as command arguments and the fal...