I am trying to estimate a model from Camerer, Ho and Chong 2002 p151.
$i$ is individual, $t$ is time
$j\in m$ which is action set
$s, a$ are two types of individuals
$s_i(t)$ is chosen action by subject $i$ in period $t$.
$P$ is probability.
$$ A^j_i(a,t)=\frac{\phi N(t-1)A^j_i(t-1)}{N(t)} +\frac{[\delta+(1-\delta)I(s^j_i,s_i(t))]\pi(s^j_i,s_{-i}(t))}{N(t)} $$ $$ N(t)=(1-\kappa)\phi N(t-1)+1, \quad t\geq 1 $$ $$ P^j_i(a,t+1)=\frac{exp(\lambda A^j_i(a,t))}{\sum^{m_i}_{k=1}exp(\lambda A^k_i(a,t))} $$ $$A^j_i(s,t)=\sum^{m_{-i}}_{k=1}[\alpha'P^k_{-i}(s,t+1)+(1-\alpha')P^k_{-i}(a,t+1)]\pi_i(s_i^j,s^k_{-i}) $$ $$ P^j_i(s,t+1)=\frac{exp(\lambda A^j_i(s,t))}{\sum^{m_i}_{k=1}exp(\lambda A^k_i(s,t))} $$ $$ L_i=\alpha[\prod^T_{t=1}P^{s_i(t)}_i(s,t)]+(1-\alpha)[\prod^T_{t=1}P^{s_i(t)}_i(a,t)] $$ $$Log L=\sum_i^n log L_i$$ Parameters needed to be estimated are $\phi$, $\delta$, $\kappa$, $\lambda$, $\alpha$, $\alpha'$.
My question is how to estimate this model using maximum likelihood model in Stata. I got error ''could not calculate numerical derivatives''. I think this is because $A^j_i(s,t)$ and $P^j_i(s,t+1)$ are dependent, but I don't know how to solve this problem.
I could also try R or Python or Matlab.