Skip to content

Discussion: add title to multiple colorbars? #361

Open
@LucaMarconato

Description

@LucaMarconato
##
from spatialdata.datasets import blobs
import spatialdata_plot
import matplotlib.pyplot as plt

sdata = blobs()
sdata['blobs_polygons']['column'] = 0

(
    sdata.pl.render_images('blobs_image')
    .pl.render_shapes('blobs_circles', color='radius')
    .pl.render_shapes('blobs_polygons', color='column')
    .pl.show()
)
plt.show()

gives
image
Which looks great! But it may be confusing to know which colorbar refers to what. I would consider one of the following:

  1. we leave it as it is: the user should use different colorbars (e.g. viridis + gray) when plotting multiple elements at the same time, so the ambiguity doesn't exist
  2. we add a title on top of the colorbar to make clear what the colorbar refers to
  3. we show only one colorbar maximum.

I prefer having multiple colorbar, so I'd choose either 1 or 2. @timtreis @Sonja-Stockhaus wdyt?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions