editing colormap for sliceplots does not work?
Hello everyone, I am trying to create custom colorbar ticks using yt 3.2.3. I am roughly following this guide: http://yt-project.org/doc/cookbook/custom_colorbar_tickmarks.html However, this approach doesn't seem to work. I attach an example script using random input data. Is this a bug? Thanks for your help! Best, Jonah
Hi Jonah, So it looks like the example in our docs isn't quite sufficiently complicated to trigger the corner case you're running into. If you make the last part of your script look like this, it works: plot = p.plots[varname] cbar = plot.cb p._setup_plots() cbar.set_ticks([]) cbar.set_ticklabels([]) I've gone ahead and issued a pull request to add a call to _setup_plots in the example in the docs to avoid confusing anyone else who is trying to do what you're doing. https://bitbucket.org/yt_analysis/yt/pull-requests/2065/add-a-call-to-_setup... -Nathan On Mon, Mar 21, 2016 at 6:40 PM, Jonah Miller < jonah.maxwell.miller@gmail.com> wrote:
Hello everyone,
I am trying to create custom colorbar ticks using yt 3.2.3. I am roughly following this guide: http://yt-project.org/doc/cookbook/custom_colorbar_tickmarks.html
However, this approach doesn't seem to work. I attach an example script using random input data. Is this a bug?
Thanks for your help!
Best, Jonah
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
Hi Nathan,
I see. Thanks a lot!
Best,
Jonah
On Tue, Mar 22, 2016, 1:36 AM Nathan Goldbaum
Hi Jonah,
So it looks like the example in our docs isn't quite sufficiently complicated to trigger the corner case you're running into. If you make the last part of your script look like this, it works:
plot = p.plots[varname] cbar = plot.cb p._setup_plots() cbar.set_ticks([]) cbar.set_ticklabels([])
I've gone ahead and issued a pull request to add a call to _setup_plots in the example in the docs to avoid confusing anyone else who is trying to do what you're doing.
https://bitbucket.org/yt_analysis/yt/pull-requests/2065/add-a-call-to-_setup...
-Nathan
On Mon, Mar 21, 2016 at 6:40 PM, Jonah Miller < jonah.maxwell.miller@gmail.com> wrote:
Hello everyone,
I am trying to create custom colorbar ticks using yt 3.2.3. I am roughly following this guide: http://yt-project.org/doc/cookbook/custom_colorbar_tickmarks.html
However, this approach doesn't seem to work. I attach an example script using random input data. Is this a bug?
Thanks for your help!
Best, Jonah
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
participants (2)
-
Jonah Miller
-
Nathan Goldbaum