In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
As a heavyweight R packet in single cell analysis, anyone who has used Seurat knows how useful it is. The Seurat analysis process basically covers all the common analysis methods in single cell analysis, including filtering,tSNE,UMAP dimensionality reduction and drawing. Another important function is to correct the batch effect between different experiments. However, the correction methods of Seurat 2 and Seurat 3 are completely different, and the results are not consistent.
Seurat 2 is based on CCA (canonical correlation), which can correct the batch effects caused by tumor, peripheral blood and paracancerous tissues, as well as the batch effects caused by different single cell experiments. Although the speed is slow, the effect is good. On the other hand, Seurat 3 is corrected based on the groups of cells with similar expression profiles between samples. For experiments of the same nature, seurat 3 can well correct the experimental batch effects caused by different single cell techniques. From the pancers correction results given on the official website, we can see how powerful its correction ability is. However, due to such a strong correction ability, the correction of tumor and peripheral blood samples has gone too far, resulting in similar gene expression profiles of cells that should not be grouped together. I have also done several topics and found that there are such problems, so I decisively give up the correction method of Seurat 3 and continue to use Seurat 2. However, the findmarker function of Seurat 3 can calculate more than 100000 cells at a time without reporting errors, while Seurat 2 is not. The compromise solution is to install packages of Seurat 2 and Seurat 3 at the same time, switch data in memory, without having to write to local and then use Seurat 3 to read and upgrade.
Especially for more than 100,000 cells, saving data locally costs at least 30min, and reading also requires 30min.
I'm going to tell you that you can perfectly switch between Seurat 2 and Seurat 3 without having to read and write locally.
In fact, the method is very simple, just install Seurat 2 and Seurat 3 in different library.
I have installed it, and take my own free handover as an example:
> R.version _ platform x86_64-conda_cos6-linux-gnuarch x861464 os linux-gnu system x861464 Linux-gnu status major 3 minor 6.1 year 2019 month 07 day 05 svn rev 76782 language R version.string R version 3.6.1 (2019-07-05) nickname Action of the Toes
I am using the latest R version 3.6.1, which works very well.
The default library comes with conda.
> .libPaths () [1] "/ data/home/heshuai/anaconda3/lib/R/library"
The default Seurat is the latest version of Seurat 3
> library (Seurat) Registered S3 method overwritten by 'R.ooze: method from throw.default R.methodsS3 > packageVersion ("Seurat") [1]' 3.0.2'
I installed Seurat 2 in another library
/ data/home/heshuai/R/x86_64-conda_cos6-linux-gnu-library
Switch freely between the two
1. First load the library where Seurat 2 is located
> .libPaths ("/ data/home/heshuai/R/x86_64-conda_cos6-linux-gnu-library") > .libPaths () [1] "/ data/home/heshuai/R/x86_64-conda_cos6-linux-gnu-library"/ data/home/heshuai/anaconda3/lib/R/library" >
2. Load Seurat 2 after detach Seurat 3, because the library where Seurat 2 is located is already before Seurat 3, and the system will load Seurat 2 by default.
> detach ("package:Seurat", unload = T) > library (Seurat) Loading required package: ggplot2RStudio Community is a great place to get help: https://community.rstudio.com/c/tidyverse.Loading required package: cowplot * * Note: As of version 1.0.0, cowplot does not change the default ggplot2 theme anymore. To recover the previous behavior, execute: theme_set (theme_cowplot ()) * Loading required package: Matrix > packageVersion ("Seurat") [1] '2.3.4' >
Now Seurat 3 has been successfully switched to Seurat 2. When you want to load Seurat 3, change the default library to the front of Seurat 2.
Is it so easy?!
Summary
The above is a tutorial for you to install Seurat2 and Seurat3 with the same version of R in linux. I hope it will be helpful to you. If you have any questions, you are welcome to leave a message and the editor will reply to you in time!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.