saeyslab / napari-sparrow

Other
17 stars 0 forks source link

Possibility to add multiple Field of Views to one sdata object #125

Open lopollar opened 1 year ago

lopollar commented 1 year ago

When needing to compare up to 30 different field of views, it would be handy to add them all to the same sdata object.

We would give them all a different coordinate reference space, so the plotting and analysis can be done separately. If one dataset is of interest, we can use sdata_ST8059048 = sdata.filter_by_coordinate_system("ST8059048") to create a subset of the dataset. I don't know how adding images to the general dataset works in this case. I think it won't be too hard to run the pipeline like this for the imaging part, as we can always specify the name of the layer used. We should just add a coordinate system variable to the function so we can add if we add the layers.

For the anndata creation, we will have to look well, as wewill have to add rows with a ket instead of a new layer. So this will be a bit of an appending and deleting mess. We will only be able to use the joint genes between all samples, as we do the pd.concat ad.concat([sdata_good0.table,sdata_good1.table,sdata_good2.table,sdata_good3.table],join='inner',label='dataset').

I don't know what you guys think of this idea.