How can I up and down justify a numpy bool array. By Justify, I mean take the True values, and move them so they are either the first values at the top (if they are up justified) or the first values at the bottom. (if they are down justified)
[[False True True True True True]
[False False True True False True]
[False True False True False False
[True True True True False True]]
So If I down justify the True values of the bool array shown above, it would look like:
[[False False False True False False]
[False True True True False True]
[False True True True False True]
[True True True True True True]]