BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
SlutskyFan
Obsidian | Level 7
Is there a way to implement markov chains models in SAS ( for forecasting purposes using transition matrices as opposed to gibbs sampler MCMC simulations)

I suppose I could define matrices in R or via SAS IML, but I'd hope that there is a PROC that can be exploited for this.

For example see:

http://www.utdallas.edu/ospa/research/Conference%20Presentations/AIR/documents/TimeHorizon.pdf

Thanks
1 ACCEPTED SOLUTION

Accepted Solutions
AndreToman
Calcite | Level 5

There is no out-of-the-box PROC that can build Markov chain forecasts that I know of.  If it's really simple with static transition probabilities, then it could be done in IML.  Alternatively, one can build dynamic Markov models using Base SAS and SAS/STAT...you don't even have to use IML.  Your transition probabilities must be computed using logistic regression.  I build migration models for account delinquency status estimation (stress testing models for the Dodd-Frank Act) using SAS 9.3.  It's lots of coding.  If I can make my code sanitary enough, I'll try to share in the SAS communities.

Andre

View solution in original post

2 REPLIES 2
Eisa
Calcite | Level 5

From my knowledge, you could implement MC (markov chains) model in proc IML.

I attached an example of code that use SAS to implement MC models in proc IML.

Some options in proc MCMC export posterior sample for other analysis. However i not sure to fully understand your need ?

AndreToman
Calcite | Level 5

There is no out-of-the-box PROC that can build Markov chain forecasts that I know of.  If it's really simple with static transition probabilities, then it could be done in IML.  Alternatively, one can build dynamic Markov models using Base SAS and SAS/STAT...you don't even have to use IML.  Your transition probabilities must be computed using logistic regression.  I build migration models for account delinquency status estimation (stress testing models for the Dodd-Frank Act) using SAS 9.3.  It's lots of coding.  If I can make my code sanitary enough, I'll try to share in the SAS communities.

Andre

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

Multiple Linear Regression in SAS

Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 6615 views
  • 0 likes
  • 3 in conversation