kaizhang / SnapATAC2

Single-cell epigenomics analysis tools
https://kzhang.org/SnapATAC2/
228 stars 26 forks source link

Add support to convert AnnData to Seurat v5 #196

Open beyondpie opened 11 months ago

beyondpie commented 11 months ago

Hi Kai,

https://github.com/beyondpie/CEMBA_wmb_snATAC/blob/c48737ddf360519231721b63cc81a0fc75d83cca/02.integration/src/main/R/annToS5.R#L36C9-L36C9

Here is how I did the transformation for gmat.

We can also think about how to transform AnnData to Signac object, where they support cicero and other analysis, too.

Songpeng

beyondpie commented 9 months ago

@kaizhang

I think I can add one R script for this task. Do you have any suggestions about adding a Rscript to this repo? I know rpy2 can call R from python, but this might be not that stable from my opinion.

Songpeng

beyondpie commented 8 months ago

Hi Kai,

I now have one single-file script for this: https://github.com/beyondpie/tools/blob/main/singlecell/SnapATACAnnData2Seurat.R

I still need some time to test it. Do you think we can put it somewhere in this repo or other place for SnapATAC2 Ann to Seurat function?

Thanks! Songpeng

beyondpie commented 8 months ago

Another potential function, should be convert SnapATAC2 AnnData to Signac object?

lf96abc commented 4 months ago

Another potential function, should be convert SnapATAC2 AnnData to Signac object?

Hi beyondpie, it would be very useful to be able to convert to Signac object. Did you ever create a script for this please?

beyondpie commented 4 months ago

@lf96abc No. I haven't used Signac before. And probably will give it a try later.

Ruismart commented 3 months ago

https://smorabit.github.io/blog/2021/velocyto/ this one works well for me by manually adding assays/metadata/reductions where they need to be from R seurat obj to Python anndata, then the reverse process should be also available~