BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Alain38
Quartz | Level 8

@PaigeMiller@Rick_SASThank you very much for help, I have now more elements to decide.

 

Don't compute the regression for this data, instead print an error message of some sort.

Knowing that I have a loop, how can I say: "If the X'X matrix is singular, then do not abort but write for example #N/A" so that when I look at the output table, I can see that for, let say t = 350 and t = 580, the matrix was not singular and these particular data points will not be used ?

 

Rick_SAS
SAS Super FREQ

if abs(det(A)) < 1e-8 then 

   /* handle singular case */

else

   /* handle nonsingular case */

  

Rick_SAS
SAS Super FREQ

For more about generalized inverses and solving the rank-deficient regression problem, see the articles

"Generalized inverses for matrices" and

"Singular parameterizations, generalized inverses, and regression estimates"

 

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

From The DO Loop
Want more? Visit our blog for more articles like these.
Discussion stats
  • 17 replies
  • 5116 views
  • 6 likes
  • 3 in conversation