I wanna set the limits of my quiver plot axes s.t. NaNs in the outer used grid do not cause my axe limits being unnecessarily long without any data points.
What I got is by myself is:
import numpy as np
pylab.xlim(np.min(Km[np.isnan(C_diff) < 0.5 ]), np.max(Km[np.isnan(C_diff) < 0.5 ]))
#two conditions: "np.min(Cm[np.isnan(K_diff) < 0.5" on min, max (Km) are missing
pylab.ylim(np.min(Cm[np.isnan(K_diff) < 0.5 ]), np.max(Cm[np.isnan(K_diff) < 0.5 ]))
#two conditions: "np.min(Km[np.isnan(K_diff) < 0.5" on min, max (Cm) are missing
To further illustrate, in matlab language I wanna have:
xlim([min(min(Km(real(~(isnan(K_diff))).*real(~(isnan(C_diff))) > 0.5))),
max(max(Km(real(~(isnan(K_diff))).*real(~(isnan(C_diff))) > 0.5)))]);
ylim([min(min(Cm(real(~(isnan(K_diff))).*real(~(isnan(C_diff))) > 0.5))),
max(max(Cm(real(~(isnan(K_diff))).*real(~(isnan(C_diff))) > 0.5)))]);
Would be great to get an answer! Thanks in advance! :)
Tobias
I guess I fixed it by:
However from the results I see no difference, but that is possible by logical operators.