Closed DomenicoSkyWalker89 closed 4 years ago
Hi @DomenicoSkyWalker89 ,
Typically we use MAGIC as the input to things like plotting gene-gene relationships and colouring dimensionality reductions by gene expression, as well as (with some care) ranking gene-gene interactions, differential expression etc. We don't typically use MAGIC as the input to dimensionality reduction.
I've tried running the tutorial you linked to, and I noticed that if you run MAGIC on the "integrated" assay, there are essentially no differences between the treatment and control; the integration is removing the biological effect. I would probably try running the entire workflow, including MAGIC, on the uncorrected data (i.e. the "RNA" assay) and seeing how things look, especially how the dimensionality reduction looks.
# load data
...
immune.combined <- RunUMAP(immune.combined)
library(Rmagic)
DefaultAssay(immune.combined) <- "RNA"
immune.combined <- magic(immune.combined)
DefaultAssay(immune.combined) <- "MAGIC_RNA"
# do the rest of your analysis
...
If it looks like you have a strong batch effect, you could try correcting it (with Seurat or otherwise) and then running MAGIC, but be warned that at least in my experience this has a high likelihood of removing some biology too.
# load data
...
immune.combined <- RunUMAP(immune.combined)
library(Rmagic)
DefaultAssay(immune.combined) <- "integrated"
immune.combined <- magic(immune.combined)
DefaultAssay(immune.combined) <- "MAGIC_integrated"
# do the rest of your analysis
...
Hi @scottgigante , Thanks a lot. I will try what you suggest!
Best, Domenico
@DomenicoSkyWalker89 Hi, I am facing the same issue. Any experience to share? Thanks!
Hi @zqun1, I performed the denoising on RNA assay as suggested by Scott and all ran perfectly. I did not noticed improvement of the data and for that i did not included this step within my final workflow(https://www.nature.com/articles/s41467-021-21928-4). I also used saverX with the same results.
Best, Domenico
@DomenicoSkyWalker89 I see. May I know what you used it for and how you decide there was no improvement? By the way, your linked paper is very interesting. Can you email me for further discussion qun.zeng@kuleuven.be ?
I am trying MAGIC to reduce dimensionality. I have integrated datasets. Without MAGIC, my clusters were very diffused on UMAP. I am trying MAGIC on "integrated" assay and interestingly, I saw the clusters were less diffused! But I am not sure if I am doing the correct thing as Scott said: How do you think @scottgigante ?
We don't typically use MAGIC as the input to dimensionality reduction.
Well, first I plotted the heatmap before and after denoising and then the distribution of single gene expression like showed in this vignette(http://htmlpreview.github.io/?https://github.com/KrishnaswamyLab/MAGIC/blob/master/Rmagic/inst/examples/bonemarrow_tutorial.html). Then i also tested if the DE genes were improved or not.
Can you share the results of UMAP embedded with clusters before and after MAGIC? Have you take into account cell cycle or mitocondrial genes etc.. as other source of variability?
ps email me for further discussion at 206560@studenti.unimore.it
Best, Domenico
Hi Scott, i have tre different data set (T0 ,T1, T2) and i used to analize this data the suggested SEURAT workflow (https://satijalab.org/seurat/v3.1/immune_alignment.html). I would use MAGIC to denoise my data, in which step of workflow su suggest to use magic? Because after integration i have two assay (RNA and integrated) and i don't understand which one to use or if there is something wrong on what i doing.
kind regard, Domenico