BookmarkSubscribeRSS Feed
SHK
Calcite | Level 5 SHK
Calcite | Level 5

I have a data set including stock_name, stock_price, volume, date, liquidity, and volatility. 

I want to regress the other variables on stock_price using the panel data analysis methods in three ways.

 

1. fixed effects on stock_name only

2. fixed effects on time only

3. fixed effects on stock_name and time at the same time

 

How can I estimate the three regression models each?

I'm using sas9.4.

 

Thanks.

 

 

1 REPLY 1
ebowen
Quartz | Level 8

Have you tried using PROC PANEL? You should be able to specify one-way and two-way fixed and random effects using the options in the model statement:

 

proc panel data=data;
   id stock_name date;
   model stock_price = volume liquidity volatility / fixone (or fixtwo);
run;

 

 

sas-innovate-2026-white.png



April 27 – 30 | Gaylord Texan | Grapevine, Texas

Registration is open

Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!

Register now

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

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