Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there a way to adjust the color scale bar? #713

Open
Mnew1288 opened this issue Dec 19, 2024 · 2 comments
Open

Is there a way to adjust the color scale bar? #713

Mnew1288 opened this issue Dec 19, 2024 · 2 comments
Labels
help wanted Extra attention is needed

Comments

@Mnew1288
Copy link

Hi Xiaojie,

Thanks so much for developing this great package!

As I analyze the differences in vector field topology between treated and untreated samples, is there a way to customize the color scale bar range for consistency when I run dyn.pl.topography and the subsequent dyn.pl.umap?

Thanks

@Mnew1288 Mnew1288 added the help wanted Extra attention is needed label Dec 19, 2024
@Sichao25
Copy link
Collaborator

Hi, thanks for raising the question. I feel like the key is the inset_dict parameter. You could try something like this:"

dyn.pl.topography(adata, basis='umap', color=['ntr'], s_kwargs_dict={"inset_dict": {"width": "5%", "height": "50%"}})
dyn.pl.umap(adata, color=["ntr"], inset_dict={"width": "5%", "height": "50%"})

@Mnew1288
Copy link
Author

Hi Sichao,

Thanks for the reply! Appreciate it!

Yes, the key seems to be the 'inset_dict". However, "width" and "height" are not going to help me as I am interested in the scale of color bar, not the size of it.

I checked here:https://matplotlib.org/stable/api/_as_gen/mpl_toolkits.axes_grid1.inset_locator.inset_axes.html

It looks like "ylim" under "axes_kwargs" parameter is the key. But how to use it in dynamo?

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants