Hey all,
Is there QR decomposition in gonum that returns the Permutation matrix/vector too?
This is useful for variable selection/responding to multicollinearity.
I'm referring to P in this matlab documentation:
[Q,R,P] = qr(A) additionally returns a permutation matrix P such that A*P = Q*R. If A is full, the permutation matrix is chosen so that abs(diag(R)) is decreasing.
example
[Q,R,P] = qr(A,outputForm) specifies whether to return the permutation information P as a matrix or a vector. For example, if outputForm is "vector", then A(:,P) = Q*R. The default value of outputForm is "matrix" such that A*P = Q*R.
So that one can do things like
I didn't see one, searching gonum in github.... or maybe gonum has a different factorization already, to do the same thing? Or it could be easily added. GSL
seems to have it; i.e.
Thanks.