Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: Problem: Mlogit: Variance Matrix nonsymmetric after bsample

Subject   st: Problem: Mlogit: Variance Matrix nonsymmetric after bsample
Date   Wed, 02 Oct 2013 15:05:54 +0200

Dear Statalist,

I would greatly appreciate your help.

I am currently trying predict the contrafactual probability of nonvoters to vote for a certain party. I am using a mlogit-model with interaction effects and difficult technique estimations options. To get more robust results, I want bootstrapped predictions using bsample. For some reason, if using bsample, after about 5 repetitions with the random samples, the mlogit-model isn't concave anymore, but apparently still converges. There's a warning message saying Variance Matrix nonsymmetric or highly singular. This results in very strange coefficients, which are still predicted und thus ruin the results. I read that this might be due to the fact that there are not enough cases with some sparse indicator variables. Therefore i tried reducing the categories in some variables, with no effect. Using the total option to see which variables produce empty cells doesn't help either.

I therefore used capture and e(p) so only regression samples w/ meaningful coeff. are included. This shows that only the first seven examples are meaningful. How can that be and what to do about it?

Thank you very much!

Here the code used (stata 10):

set seed 731

	forv i = 1/200 {
				bsample, strata(Wä)

		// Loop over dates and surveys

				// Estimate model
capture mlogit party _I* [pweight=wei_ipfges_2] if party <= 5, difficult technique(nr 15 bhhh 15 dfp 15 bfgs 15) base(1)

		if e(p)~= . {

			// Predict
			predict Phat1 Phat2 Phat3 Phat4 Phat5 if Wä == 0

			// Post
			forv j = 1/5 {
				sum Phat`j' [aw=wei_ipfges_2] if Wä==0, meanonly
				post `CI' (`j') (r(mean))

					drop Phat*


postclose `CI'


*   For searches and help try:

© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index