If I have an numpy array like the one below, how can I right justify or left justify the elements tat are greater than zero
[[ 0. 5. 0. 2.]
[ 0. 0. 3. 2.]
[ 0. 0. 0. 0.]
[ 2. 0. 0. 1.]]
for example, If I wanted to right justify this array, it would look like:
[[ 5. 2. 0. 0.]
[ 3. 2. 0. 0.]
[ 0. 0. 0. 0.]
[ 2. 1. 0. 0.]]