You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In a lot of situations it's useful to remove the redundant or trivial (diagonal) entries from a correlation matrix. For example, if you want to query a correlation matrix to find highly or perfectly correlated columns you have to find some way of manually ignoring the diagonal, or if you want to remove only one of two highly correlated columns, it's useful to be working only with the lower triangular form.
Therefore I think it would be very useful to add a boolean argument to DataFrame.corr which specifies if the lower triangular correlation matrix should be returned (if the upper triangular is desired the user can take the transpose) instead of the full.
The text was updated successfully, but these errors were encountered:
If we were to include a tri argument, I would prefer a tri=None(default)/'upper'/'lower' instead of tri=True/False for just the lower triangular so users can have the option of the upper triangular.
In your implementation, it appears fill value would be NaN as opposed to numpy (triu/trul) which the fill value is 0. I am not sure what the preferred fill value should be, but in general we try to stay consistent with numpy conventions.
In a lot of situations it's useful to remove the redundant or trivial (diagonal) entries from a correlation matrix. For example, if you want to query a correlation matrix to find highly or perfectly correlated columns you have to find some way of manually ignoring the diagonal, or if you want to remove only one of two highly correlated columns, it's useful to be working only with the lower triangular form.
Therefore I think it would be very useful to add a boolean argument to
DataFrame.corr
which specifies if the lower triangular correlation matrix should be returned (if the upper triangular is desired the user can take the transpose) instead of the full.The text was updated successfully, but these errors were encountered: