Hello everyone,

I am a beginner of STATA and want to estimate a model:

There are two firms 1 and 2, which have characteristics X1 and X2. They decide whether to enter a market or not (y

Now I know that the probability of both firms entering is Pr(y

I have the data of entrance decision (y1 and y2) and X1 X2, I want to estimate b1 b2 and delta.

I write the log-likelihood function as

This is just L = (1-y1)(1-y2) ln Pr(2) + y1y2 ln Pr(0) +[(1-y1)y2+(1-y2)y1] ln Pr(1).

However, I do not know how to estimate the MLE in STATA. A simple MLE does not work as I have two independent variables and code "

The problem is that I have three cases in the likelihood function and do not know how to write it properly.

If anyone has any suggestion, please leave a reply.

Thank you so much!!

I am a beginner of STATA and want to estimate a model:

There are two firms 1 and 2, which have characteristics X1 and X2. They decide whether to enter a market or not (y

_{i}=1 means to enter and y_{i}=0 means not), the cost of entry, if the other firm enters, is delta. So the profit of the firms are**Z**where e_{i}=y_{i}(X_{i}b_{i }+ delta y_{-i}+e_{i}),_{i}is iid normal and e_{1, }e_{2}are independent.Now I know that the probability of both firms entering is Pr(y

_{1}=1 and y_{2}=1) = Φ(-X_{1}b_{1})Φ(−X_{2}b_{2}), no firm enters is Pr(y_{1}=0 and y_{2}=0)= (1-Φ(-X_{1}b_{1}-delta))*(1-Φ(-X_{2}b_{2}-delta) and one firm enters is 1-Pr(2)-Pr(0).I have the data of entrance decision (y1 and y2) and X1 X2, I want to estimate b1 b2 and delta.

I write the log-likelihood function as

**L =(1-y1)(1-y2)[ ln Φ(-X1b1)+lnΦ(−X2b2)] + (y1y2)[ln (1-Φ(-X1b1-delta)) + ln (1-Φ(-X2b2-delta)] +[(1-y1)y2+(1-y2)y1] {ln(1-Φ(-X1b1)Φ(−X2b2))-[(1-Φ(-X1b1-delta))*(1-Φ(-X2b2-delta]}.**This is just L = (1-y1)(1-y2) ln Pr(2) + y1y2 ln Pr(0) +[(1-y1)y2+(1-y2)y1] ln Pr(1).

However, I do not know how to estimate the MLE in STATA. A simple MLE does not work as I have two independent variables and code "

**mvprobit (y1=x1) (y2=x2)"**does not work.The problem is that I have three cases in the likelihood function and do not know how to write it properly.

If anyone has any suggestion, please leave a reply.

Thank you so much!!