Search found 31 matches

by tjsduq64
Thu Apr 02, 2020 4:31 am
Forum: MLwiN user forum
Topic: MCMC and weights for a multilevel logistic regression
Replies: 1
Views: 2816

MCMC and weights for a multilevel logistic regression

Hello, A document on the website (http://www.bristol.ac.uk/cmm/software/support/support-faqs/weights.html) called "Weights in MLwiN" by Rebecca Pillinger states that MLwin cannot use weights in an MCMC analysis. This document was written in 2011. Is this still the case? I need to fit a mul...
by tjsduq64
Thu Apr 02, 2020 3:56 am
Forum: R2MLwiN user forum
Topic: R2MLwiN and multilevel multiple imputation
Replies: 10
Views: 25736

Re: R2MLwiN and multilevel multiple imputation

Not sure if this helps, if I use debugmode=TRUE and see what is happening in MLwiN, I find that MLwiN turns "not responding" before I get this error.

Code: Select all

v gone -ve definite for block 0 iteration aborted(fixed pass)
by tjsduq64
Thu Apr 02, 2020 2:53 am
Forum: R2MLwiN user forum
Topic: R2MLwiN and multilevel multiple imputation
Replies: 10
Views: 25736

Re: R2MLwiN and multilevel multiple imputation

1. Ah, I see that MLwiN uses multivariate model to impute missing data, very cool. The manual says imputing an ordered categorical variable is under research. What about binary variables and multinomial (unordered) variables? If these work, I will definitely use this option since using mice seems a ...
by tjsduq64
Wed Apr 01, 2020 2:23 am
Forum: R2MLwiN user forum
Topic: presenting MCMC visuals on rmarkdown
Replies: 11
Views: 19801

Re: presenting MCMC visuals on rmarkdown

Adding BD function works perfectly now for the sixway function. The last error I am having is that when I have more than 6 parameters in the model and trajectories functions will have to display more than 6 plots, it only shows the first 6 plots. When I do not knit via rmarkdown and just run the cod...
by tjsduq64
Tue Mar 31, 2020 3:08 pm
Forum: R2MLwiN user forum
Topic: presenting MCMC visuals on rmarkdown
Replies: 11
Views: 19801

Re: presenting MCMC visuals on rmarkdown

Ah, gotcha. I added MCSE manually and now the next function BD is not being picked up. Probably something wrong with my current setup in the environment. Thank you.

Sun
by tjsduq64
Tue Mar 31, 2020 2:40 pm
Forum: R2MLwiN user forum
Topic: presenting MCMC visuals on rmarkdown
Replies: 11
Views: 19801

Re: presenting MCMC visuals on rmarkdown

When I used the new version of sixway (removing the line 119 from the older version), I only get the first four plots out of the six (first two rows of 2 by 3 plots) + summary statistics, and also get the error, Error in MCSE(flatchain, rho, ll = 0.5, ul = 20) : could not find function "MCSE&qu...
by tjsduq64
Tue Mar 31, 2020 11:40 am
Forum: R2MLwiN user forum
Topic: presenting MCMC visuals on rmarkdown
Replies: 11
Views: 19801

Re: presenting MCMC visuals on rmarkdown

Hi Chris, thank you for your help and sorry for the late reply. That's good news that the new version of the package will fix this. I have a question about your suggestion. I don't see dev.new anywhere in the link you sent me. I may just be not understanding the programming part. I nonetheless delet...
by tjsduq64
Thu Mar 26, 2020 3:15 am
Forum: R2MLwiN user forum
Topic: presenting MCMC visuals on rmarkdown
Replies: 11
Views: 19801

Re: presenting MCMC visuals on rmarkdown

Additional concern: I also noticed that what gets included in the final document changes every time I knit the document, even with the same codes. So, when I run a single document of codes multiple times, sometimes trajectories get included and other times, sixway.
by tjsduq64
Thu Mar 26, 2020 2:57 am
Forum: R2MLwiN user forum
Topic: presenting MCMC visuals on rmarkdown
Replies: 11
Views: 19801

presenting MCMC visuals on rmarkdown

Hi, I am using R2MLwiN to run a model via MCMC and presenting the diagnostics by knitting a R markdown file into a html document. This code on rmarkdown (i.e., open a rmarkdown and run this code) creates "test.Rmd" that I want to knit. ```{r} ## Read tutorial data data(tutorial, package = ...
by tjsduq64
Tue Mar 24, 2020 2:57 pm
Forum: R2MLwiN user forum
Topic: R2MLwiN and multilevel multiple imputation
Replies: 10
Views: 25736

Re: R2MLwiN and multilevel multiple imputation

Thanks Chris. It seems like, if I want to use R2MLwiN, my options are running a RIGLS model with Realcom or with mice. Does MCMC work with Realcom or mice? It seems like Realcom won't work, and I am not sure if mice takes mlwinMCMC object. I may need to use MCMC since my outcome is a binary variable...