In the above plot, Colorbar range is approximately Mass=10^5-10^9. When making a plot using ParticlePlot or ParticleProjectionPlot, can I manually force the range on the colorbar?
You can use the .set_zlim() function to set the colorbar range in any
PlotWindow object (e.g. ProjectionPlot, ParticlePlot, etc). In this instance, try: p.set_zlim('particle_mass', 1e6, 1e7).
- The label on the colorbar says "Particle Mass". Instead, shouldn't it
be saying something like mass_per_pixel, since the plot is showing the total number of particles projected along the z-axis? How can we rename the colorbar?
I think you'll have to modify the MPL labels of the p.cax y-axis label.
- Can contours of mass be added to the above plot, using annotate?
Unfortunately, the annotate_contour() callback I don't think is working with ParticlePlots yet.