PREGRESS

Questions related to panel (pooled cross-section time series) data.
smukherjee01
Posts: 21
Joined: Mon Jul 14, 2014 9:58 am

Re: PREGRESS

Unread post by smukherjee01 »

Thank you, Tom.

Two questions:

1. Can we use clustered standard errors in SUR?

2. I want to estimate the equation

PFE = CONSTANT + EXP (LOG ((1-G)/G))* PFR + GAMMA*BPOF

Here my second coefficient (Beta 2) is EXP (LOG ((1-G)/G)) and my third coefficient (Beta 3) is GAMMA. I don't have G, but when I get EXP (LOG ((1-G)/G)), I will calculate the value of G.


Writing the following command but getting error message:


OPEN DATA "C:\EXAMPLE1.xlsx"
DATA(FORMAT=XLSX,ORG=COLUMNS) 1 503 FEV For OFM
SET PFE = For *10
SET PFR = FEV*10
SET BPOF = (OFM*50)/100

NONLIN G GAMMA
FRML C = CONSTANT + EXP(LOG((1-G)/G))* PFR + GAMMA*BPOF
NLLS (FRML=C) PFE
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: PREGRESS

Unread post by TomDoan »

smukherjee01 wrote: Two questions:

1. Can we use clustered standard errors in SUR?
Yes. https://estima.com/ratshelp/robusterroroptions.html
smukherjee01 wrote: 2. I want to estimate the equation

PFE = CONSTANT + EXP (LOG ((1-G)/G))* PFR + GAMMA*BPOF

Here my second coefficient (Beta 2) is EXP (LOG ((1-G)/G)) and my third coefficient (Beta 3) is GAMMA. I don't have G, but when I get EXP (LOG ((1-G)/G)), I will calculate the value of G.


Writing the following command but getting error message:


OPEN DATA "C:\EXAMPLE1.xlsx"
DATA(FORMAT=XLSX,ORG=COLUMNS) 1 503 FEV For OFM
SET PFE = For *10
SET PFR = FEV*10
SET BPOF = (OFM*50)/100

NONLIN G GAMMA
FRML C = CONSTANT + EXP(LOG((1-G)/G))* PFR + GAMMA*BPOF
NLLS (FRML=C) PFE
Why do you have EXP(LOG(x))? Wouldn't that just be x?

You have a space between NLLS and (FRML=C).
smukherjee01
Posts: 21
Joined: Mon Jul 14, 2014 9:58 am

Re: PREGRESS

Unread post by smukherjee01 »

Thank you for SUR and NLLS.

However I am not getting what I want in NLLS.

Actually my Beta 2 is (1-G)/G. I have a condition that 0<G<=1.

Hence, 0<=(1-G)/G<+ infinity.

The regression coefficient in RATS can take any value between negative infinity and positive infinity.

Hence, if I define it in the way I have done (now) I can trick RATS to think that the regression coefficient varies from negative infinity and positive infinity.

I changed EXP (LOG ((1-G)/G))b] and wrote LOG (EXP ((1-G)/G)).

PFE = CONSTANT + LOG (EXP ((1-G)/G))* PFR + GAMMA*BPOF

However, I want the output of LOG (EXP ((1-G)/G)), so that I can compute G myself. I am not getting that, as RATS wants me to set initial values for the parameters by using the command COMPUTE.

I am confused as what to set the initial values of the parameters.

OPEN DATA "C:\EXAMPLE1.xlsx"
DATA(FORMAT=XLSX,ORG=COLUMNS) 1 503 FEV For OFM
SET PFE = For *10
SET PFR = FEV*10
SET BPOF = (OFM*50)/100

NONLIN G GAMMA
FRML C = LOG(EXP((1-G)/G))* PFR + GAMMA*BPOF
COMPUTE G=1.0
COMPUTE GAMMA=1.0
NLLS(FRML=C) PFE


I am not being able to use the constant term as well.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: PREGRESS

Unread post by TomDoan »

1. log(exp(x)) can take any sign, so that certainly won't give you the restriction that you want.
2. Coding a coefficient as exp(z) to try to enforce non-negativity is bad practice, since it forces positivity, not non-negativity. If the least squares estimator is at the 0 boundary, then exp(z) can never reach that and instead will push z towards -infinity.
3. Why wouldn't you just use a parameter set with restrictions? https://estima.com/ratshelp/parmsetdatatype.html.
4. Since you have just the one constraint, if you do NLLS and it doesn't meet the constraint, the optimum is at the boundary. It might not be very interesting, but that's what it is.
5. You have to put in a parameter for the intercept, not CONSTANT. CONSTANT simply evaluates to the fixed 1.0.
smukherjee01
Posts: 21
Joined: Mon Jul 14, 2014 9:58 am

Re: PREGRESS

Unread post by smukherjee01 »

Thank you for this. I really appreciate your help.
Post Reply