I have a scatter plot with the points shaded according to a third variable. I want to use a symmetric logarithmic scale for my colormap as described in the api: SymLogNorm
Unfortunately I get the following error:
TypeError: array cannot be safely cast to required type
Here a mini example. I'm using matplotlib 1.3.0.
# loading modules
import matplotlib as mpl
import matplotlib.pyplot as plt
# defining variables
x=[0,1,2,3]
y=[0,1,2,3]
c=[-1000,-100,100,1000]
# making scatterplot
plt.scatter(x, y, c=c, norm=mpl.colors.SymLogNorm(linthresh=10))
Without the symmetric logarithmic colormap the plot works fine.
plt.scatter(x, y, c=c)
Thank you very much for your help.
