NOTE: Your code contains 7 program statements.
NOTE: Gradient is computed using analytic formulas.
NOTE: Hessian is computed using analytic formulas.
ERROR: Execution Errors for _OBS_= 2 :
ERROR: There are references to missing variables when the program code is executed for _OBS_= 2
WARNING: Your program statements cannot be executed completely.
WARNING: In a total of 1 calls an error occurred during execution of the program statements. NLP attempted to recover by using
a shorter step size.
我的编程如下所示:
- proc nlp data=a4 vardef=n covariance=h pcov phes outest=b covariance=h pall tech=newrap;
- profile beta delta;
- max loglik;
- parms beta=-1,delta=1;
- bounds delta>0;
- /*中间是似然函数的表示,,太多了就省略了*/;
- loglik=c1*y1+c2*y2+c3*y3+c4*y4+c5*y5+c6*y6;
- run;
- proc mcmc data=a4 nmc=5000 outpost=a5 statistics=(summary) diagnostics=none thin=5 seed=246810;
- parms beta 1 delta 1;
- prior beta~normal(0,var=1);
- prior delta~gamma(1.4,scale=3.5);
- /*中间是同样的似然函数表示,太多省略*/;
- model general(y);
- run;