%eqnxvector instruction
Posted: Wed Nov 11, 2009 3:59 am
To whom it might concern:
I have estimated the following nonlinear model:
stat(noprint) diflrop
compute scalef=1.0/sqrt(%variance)
lin(define=standard,noprint) diflrop
# diflrop{1}
frml(equation=standard,vector=phi1) phi1f
do i=1,1
compute phi1(i)=%beta(i)
end do
lin(define=transit,noprint) diflrop
# diflrop{1 to 2} diflrop{4} diflrop{6}
frml(equation=transit,vector=phi2) phi2f
do j=1,4
compute phi2(j)=%beta(j)
end do
nonlin(parmset=regparms) phi1 phi2
nonlin(parmset=starparms) gamma
frml flstar = 1/(1+exp(-gamma*scalef*(diflwop{5})))
frml lstar diflwop=f=flstar,phi1f+f*phi2f
compute gamma = 1
nlls(frml=lstar,parmset=regparms+starparms,method=simplex,iters=5) diflrop
nlls(frml=lstar,parmset=regparms+starparms,cvcrit=0.0001) diflrop / resids
then I want to do some misspecification test. For this purpose I need to extract some vectors as follows:
compute standsize=%eqnsize(standard)
compute transize=%eqnsize(transit)
dec rect[series] standreg(2,standsize)
dec rect[series] transreg(2,transize)
dec rect[series] teststand(3,standsize)
dec rect[series] testtrans(3,transize)
do i=1,standsize
set standreg(1,i)=flstar*%eqnxvector(standard,i)
set standreg(2,i)=(1-flstar)*eqnxvector(standard,i)
end do i
bur at this point a message error appears:
Can't Interpret FRML * VECTOR
## SX27. Illegal Combination of Data Types for Operation
>>>>vector(standard,i)<<<<
I can not figure out where is the problem. Help will be very welcome.
Best regards,
Javi
(moderator: edited message title to reflect correct function name)
I have estimated the following nonlinear model:
stat(noprint) diflrop
compute scalef=1.0/sqrt(%variance)
lin(define=standard,noprint) diflrop
# diflrop{1}
frml(equation=standard,vector=phi1) phi1f
do i=1,1
compute phi1(i)=%beta(i)
end do
lin(define=transit,noprint) diflrop
# diflrop{1 to 2} diflrop{4} diflrop{6}
frml(equation=transit,vector=phi2) phi2f
do j=1,4
compute phi2(j)=%beta(j)
end do
nonlin(parmset=regparms) phi1 phi2
nonlin(parmset=starparms) gamma
frml flstar = 1/(1+exp(-gamma*scalef*(diflwop{5})))
frml lstar diflwop=f=flstar,phi1f+f*phi2f
compute gamma = 1
nlls(frml=lstar,parmset=regparms+starparms,method=simplex,iters=5) diflrop
nlls(frml=lstar,parmset=regparms+starparms,cvcrit=0.0001) diflrop / resids
then I want to do some misspecification test. For this purpose I need to extract some vectors as follows:
compute standsize=%eqnsize(standard)
compute transize=%eqnsize(transit)
dec rect[series] standreg(2,standsize)
dec rect[series] transreg(2,transize)
dec rect[series] teststand(3,standsize)
dec rect[series] testtrans(3,transize)
do i=1,standsize
set standreg(1,i)=flstar*%eqnxvector(standard,i)
set standreg(2,i)=(1-flstar)*eqnxvector(standard,i)
end do i
bur at this point a message error appears:
Can't Interpret FRML * VECTOR
## SX27. Illegal Combination of Data Types for Operation
>>>>vector(standard,i)<<<<
I can not figure out where is the problem. Help will be very welcome.
Best regards,
Javi
(moderator: edited message title to reflect correct function name)