Hello everyone,

I am estimating an endogenous switching regression model by means of ssm. This latter should allow for probability weights, however my code stops working when I include them.

This code without including probability weights perfectly works.

Code:
 ssm y $myx endummy , switch(endummy = $myz) adapt q(16) family(binom) link(probit)
The same exact code but including weights

Code:
ssm y $myx endummy [pw=weights], switch(endummy = $myz) adapt q(16) family(binom) link(probit)
returns me the following error

no observations
r(2000);
Does anybody know how to include probability weights when estimating these kinds of model?
Thank you in advance