BookmarkSubscribeRSS Feed
thdang
Calcite | Level 5

Hi, I would like to run a regression like this one:

proc model data = datain;

    parms labda bm_0 bm_1 bm_2 bm_3 bm_4 bm_5 bm_6 bm_7 bm_8 bm_9 bm_10

            beta_0 beta_1 beta_2 beta_3 beta_4 beta_5 beta_6 beta_7 beta_8 beta_9 beta_10 mean_factor;

    eq.m1 = p_mretrf-beta_0*(labda-mean_factor)-b_0*mkt_rf - beta_0*MDI  ( if id = 0) ........  ;

    eq.m2=mdi*(p_mretrf-beta_0*(labda-mean_factor)-b_0*mkt_rf - beta_0*MDI) ( if id = 0) .......... ;

    fit m1 m2 /gmm kernel=(bart,1,0);

run;

And I want to add the same thing for Id = 1,...,10.

For a normal regression I would include "by id;". But the probleem here is that I just want to have 1 labda for all of them, but different id have different beta's and b's (that is why beta_0 to beta_10).

Can someone please help me with this?

Many thanks!

1 REPLY 1
SteveDenham
Jade | Level 19

For PROC MODEL help, you might want to post this in the Forecasting and Econometrics forum.

Steve Denham

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 646 views
  • 0 likes
  • 2 in conversation