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"