Uh oh!
There was an error while loading. Please reload this page.
updated read_visium() to read in spaceranger 2.0 files - #2424
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@## master #2424 +/- ##
=======================================
Coverage 71.87% 71.87% =======================================
Files 98 98 Lines 11496 11496 =======================================
Hits 8263 8263 Misses 3233 3233
|
10x Visium data from both space ranger 1.0.0 and 2.0.0 can be read in using space ranger 1.0.0 data from 10x plotted with squidpy's space ranger 2.0.0 data from 10x plotted with squidpy's |
LLehner
commented
Feb 20, 2023
giovp
commented
Mar 1, 2023
LLehner
commented
Mar 6, 2023
sure, will do |
giovp
commented
Apr 2, 2023
LGTM thanks @LLehner ! |
hi @LLehner, why is this |
hi @flying-sheep, you are right. Header should be 0, otherwise the first row with values (besides the barcode) will be turned into headers and then overwritten. Didn't catch that before, since it didn't cause issues in the plotting examples. |
Folks. Forgive my ignorance if I am completely wrong but it seems read_visium still reads it wrong. another edit: Lines 466 to 482 in 89804c2 Basically line 476 is fixes the switch and makes the barcode coordinates in (x,y). I apologise for the confusion. |
grst
commented
Jan 25, 2024
With scverse/spatialdata-io#102 we could consider replacing defread_visium(*args, **kwargs): importspatialdata_ioreturnspatialdata_io.visium(*args, **kwargs).to_legacy_anndata()and avoid maintaing the annoying spaceranger output parsing in multiple locations. |


Can now read in spaceranger 2.0 files where the tissue position file name is different and a header is included. Code adapated from squidpy's read.visium() in response to scverse/squidpy#599 and scverse/scanpy#2296.