Add multiplier to logscale colorer

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Add multiplier to logscale colorer

Nunzio Losacco
Hi all,

I am producing a contour plot with a lognormalized colorbar.
If the levels are set to numpy.logspace(expmin,expmax,num) * mul
the colorbar labels disappear.
I would like them to be

“mul x 10^exp “

I have been playing a lot with formatters but I didn’t manage to obtain what I want.

Any help?

N

*****************************************************************

Dr. Nunzio Losacco
(PhD, MEng, MSc, DIC)
PostDoctoral Fellow
University of Rome "Tor Vergata"
Department of Civil Engineering and Computer Science
Via del Politecnico, 1 - 00133 - Roma
Italy

+39 0672597062

*****************************************************************




_______________________________________________
Matplotlib-users mailing list
[hidden email]
https://mail.python.org/mailman/listinfo/matplotlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Add multiplier to logscale colorer

Saito Kotaro (PSI)
Hi Nunzio,

Colorbar in matplotlib is a bit tricky. Solutions for your problem might be different depending on whether you are using fig.colorbar or colorbar in ImageGrid.
Can you show me a minimal working example?


//================//================//
Paul Scherrer Institut
Kotaro SAITO 斉藤耕太郎
Laboratory for Neutron Scattering and Imaging
WHGA/348
5232 Villigen PSI, Schweiz
+41 56 310 3179
[hidden email]
https://sites.google.com/view/kotarosaito/
//================//================//

> On 2018/2/ 15, at 00:58, Nunzio Losacco <[hidden email]> wrote:
>
> Hi all,
>
> I am producing a contour plot with a lognormalized colorbar.
> If the levels are set to numpy.logspace(expmin,expmax,num) * mul
> the colorbar labels disappear.
> I would like them to be
>
> “mul x 10^exp “
>
> I have been playing a lot with formatters but I didn’t manage to obtain what I want.
>
> Any help?
>
> N
>
> *****************************************************************
>
> Dr. Nunzio Losacco
> (PhD, MEng, MSc, DIC)
> PostDoctoral Fellow
> University of Rome "Tor Vergata"
> Department of Civil Engineering and Computer Science
> Via del Politecnico, 1 - 00133 - Roma
> Italy
>
> +39 0672597062
>
> *****************************************************************
>
>
>
> _______________________________________________
> Matplotlib-users mailing list
> [hidden email]
> https://mail.python.org/mailman/listinfo/matplotlib-users

_______________________________________________
Matplotlib-users mailing list
[hidden email]
https://mail.python.org/mailman/listinfo/matplotlib-users