Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhenyiWangTHU committed Oct 22, 2024
1 parent 0c1e26e commit cf18976
Show file tree
Hide file tree
Showing 29 changed files with 363 additions and 143 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
h1:installation Installation
h2:create-a-new-conda-environment-and-activate-it Create a new conda environment and activate it
h2:set-the-channels-in-conda Set the channels in conda
h2:install-r-and-python Install R and python
h2:install-r Install R
h2:install-required-r-packages Install required R-packages
h2:create-the-required-python-virtual-environment Create the required python virtual environment
h2:create-the-required-python-v.3.9.12-virtual-environment Create the required python (v.3.9.12) virtual environment
h2:the-installed-packages-with-versions The installed packages with versions

2 changes: 1 addition & 1 deletion .Rproj.user/F5A33326/pcs/source-pane.pper
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"activeTab": -1
"activeTab": 0
}
2 changes: 1 addition & 1 deletion .Rproj.user/F5A33326/pcs/windowlayoutstate.pper
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"left": {
"splitterpos": 103,
"topwindowstate": "HIDE",
"topwindowstate": "NORMAL",
"panelheight": 1312,
"windowheight": 1350
},
Expand Down
26 changes: 26 additions & 0 deletions .Rproj.user/F5A33326/sources/per/t/9679D688
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"id": "9679D688",
"path": "D:/GitHub/HemaScope_Tutorial/01-HemaScope_installation_tutorial.Rmd",
"project_path": "01-HemaScope_installation_tutorial.Rmd",
"type": "r_markdown",
"hash": "797006684",
"contents": "",
"dirty": false,
"created": 1729562861292.0,
"source_on_save": false,
"relative_order": 1,
"properties": {
"source_window_id": "",
"Source": "Source",
"cursorPosition": "162,33",
"scrollLine": "123"
},
"folds": "",
"lastKnownWriteTime": 1729562922,
"encoding": "UTF-8",
"collab_server": "",
"source_window": "",
"last_content_update": 1729562922491,
"read_only": false,
"read_only_alternatives": []
}
192 changes: 192 additions & 0 deletions .Rproj.user/F5A33326/sources/per/t/9679D688-contents
Original file line number Diff line number Diff line change
@@ -0,0 +1,192 @@
# Installation

## Create a new conda environment and activate it

```
conda create --name HemaScope_env
conda activate HemaScope_env
```

## Set the channels in conda

```
# Add the default channel
conda config --add channels defaults

# Add default channel URLs
conda config --add default_channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main
conda config --add default_channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r
conda config --add default_channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/msys2

# Add custom channels
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/menpo
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch-lts
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/simpleitk
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/deepmodeling

# Set to show channel URLs
conda config --set show_channel_urls true
```

## Install R

- R 4.3.3

```
conda install R-base=4.3.3
```

## Install required R-packages

- From conda

```
conda install -c conda-forge r-devtools=2.4.5 -y
conda install -c conda-forge r-Seurat=4.3.0.1 -y
conda install -c conda-forge r-Rfast2=0.1.5.1 -y
conda install -c conda-forge r-hdf5r=1.3.10 -y
conda install -c conda-forge r-ggpubr=0.6.0 -y
conda install pwwang::r-seuratwrappers -y
conda install -c bioconda bioconductor-monocle=2.28.0 -y
conda install -c bioconda bioconductor-slingshot=2.8.0 -y
conda install -c bioconda bioconductor-GSVA=1.48.2 -y
conda install -c bioconda bioconductor-org.Mm.eg.db=3.17.0 -y
conda install -c bioconda bioconductor-org.Hs.eg.db=3.17.0 -y
conda install -c bioconda bioconductor-scran=1.28.1 -y
conda install -c bioconda bioconductor-AUCell=1.22.0 -y
conda install -c bioconda bioconductor-RcisTarget=1.20.0 -y
conda install -c bioconda bioconductor-GENIE3=1.24.0 -y
conda install -c bioconda bioconductor-biomaRt=2.56.1 -y
conda install -c bioconda r-velocyto.r=0.6 -y
#conda install -c bioconda bioconductor-limma=3.56.2 -y
```
- Enter the R language environment

We suggest users do not manually update any already installed R packages during the installation of the following R packages.
```
R
```
- From BiocManager

```
# BiocManager(version = "1.30.23") should already be installed as a dependency of r-seuratwrappers.
# If it is not installed, please run the following code to install it.
# install.packages("BiocManager",version="1.30.23")
BiocManager::install("ComplexHeatmap")
BiocManager::install("scmap")
BiocManager::install("clusterProfiler")
BiocManager::install("BiocNeighbors")
```

- From CRAN

```
install.packages(c("doMC",
"doRNG",
"shinyjs",
"shiny",
"shinyWidgets",
"shinydashboard",
"slickR",
"phateR",
"gelnet",
"parallelDist",
"kableExtra",
"transport",
"feather",
"markdown",
"ggalluvial",
"forcats",
"mcmc",
"MCMCpack",
"fields",
"getopt",
"osfr"))
```

- From GitHub

tips:

Sometimes network connection issues may occur, resulting in an error message indicating that GitHub cannot be connected. Please try installing again when the network conditions improve.

Usage limitations: Sometimes an API rate limit error occurs, and a GitHub token is needed to provide the GitHub API rate limit. The steps to resolve this are as follows: Register for an account or log in to an existing account on the GitHub website. Then click on your profile picture in the top right corner, go to the dropdown menu and select "Settings." Next, find "Developer settings" and click on it, then find "Personal access tokens (classic)." Click on it, then click "Create new token (classic)." Create a new token by first naming it anything you like. Then choose the expiration time for the token. Finally, check the "repo" box; the token will be used to download code repositories from GitHub. Click "Generate token." Copy the generated token password.

After that, set the token in the environment variable in R. Since we are using conda, enter R by typing R in the terminal. Then, enter the command: usethis::edit_r_environ(). This will open a file. Press the i key to edit. Paste the token you copied into the code area as follows: GITHUB_TOKEN="your_token".

Then press Esc, type :wq! (force save). After that, you need to exit Linux and re-enter R. Close and reopen the terminal to apply the environment variable. Reopen Linux, activate the conda environment, and enter R again.

```
devtools::install_github("sqjin/CellChat")
devtools::install_github("immunogenomics/presto")
devtools::install_github("aertslab/SCENIC@140ad6b")
devtools::install_github("pzhulab/abcCellmap@f44c14b")
devtools::install_github("navinlabcode/copykat@d7d6569")
devtools::install_github('chris-mcginnis-ucsf/DoubletFinder@8c7f76e')
devtools::install_github("mojaveazure/seurat-disk@877d4e1")
devtools::install_github(c("hfang-bristol/dnet"))

```

- Install HemaScopeR from github

```
devtools::install_github(repo="ZhenyiWangTHU/HemaScopeR", dep = FALSE)
```

<!-- - Exist the R language environment -->
<!-- ``` -->
<!-- quit() -->
<!-- ``` -->

<!-- ## Install required Python-packages -->

<!-- - Upgrade pip and set mirrors -->

<!-- ``` -->
<!-- python -m pip install -i https://pypi.tuna.tsinghua.edu.cn/simple --upgrade pip -->
<!-- pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple -->
<!-- pip config set global.extra-index-url http://mirrors.aliyun.com/pypi/simple/ -->
<!-- ``` -->

<!-- - Install required packages -->

<!-- ``` -->
<!-- pip install anndata arboreto cell2location commot karateclub matplotlib networkx phate pot scanpy scipy scvi-tools seaborn distributed radian dask==2022.2.1 distributed==2022.2.1 scvelo==0.2.5 numpy==1.23.5 pandas==1.5.3 -->
<!-- # stereopy==1.3.1 -->
<!-- ``` -->

## Create the required python (v.3.9.12) virtual environment

- Run the `init_miniconda` function to create the miniconda virtual environments for the scRNA-seq pipeline and ST pipeline of 10X Visium data and MERFISH data.

```
library(HemaScopeR)
init_miniconda()
```

- (Optional) Run the `init_miniconda_stereo` function to create the miniconda virtual environment for the stereo-seq data.

```
init_miniconda_stereo()
```



## The installed packages with versions
- R packages with versions
```
Package Version
------- -------

```
- Python packages with versions
```
Package Version
------------------------ --------------

```
4 changes: 2 additions & 2 deletions .Rproj.user/F5A33326/sources/prop/68A8727B
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"source_window_id": "",
"Source": "Source",
"cursorPosition": "15,25",
"scrollLine": "0"
"cursorPosition": "162,33",
"scrollLine": "123"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"chunk_definitions":[],"doc_write_time":1729562870}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"chunk_definitions":[],"doc_write_time":1728717061}
{"chunk_definitions":[],"doc_write_time":1729562870}
49 changes: 25 additions & 24 deletions 01-HemaScope_installation_tutorial.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,16 @@ conda config --set show_channel_urls true

## Install R

<<<<<<< Updated upstream
<!-- - R 4.3.3 and python 3.9.12 -->
=======
>>>>>>> Stashed changes
- R 4.3.3

```
conda install R-base=4.3.3
```

<!-- conda install python=3.9.12 -->

## Install required R-packages

- From conda
Expand Down Expand Up @@ -88,27 +89,27 @@ BiocManager::install("BiocNeighbors")
- From CRAN

```
install.packages("doMC")
install.packages("doRNG")
install.packages("shinyjs")
install.packages("shiny")
install.packages("shinyWidgets")
install.packages("shinydashboard")
install.packages("slickR")
install.packages("phateR")
install.packages("gelnet")
install.packages("parallelDist")
install.packages("kableExtra")
install.packages("transport")
install.packages("feather")
install.packages("markdown")
install.packages("ggalluvial")
install.packages("forcats")
install.packages("mcmc")
install.packages("MCMCpack")
install.packages("fields")
install.packages("getopt")
install.packages("osfr")
install.packages(c("doMC",
"doRNG",
"shinyjs",
"shiny",
"shinyWidgets",
"shinydashboard",
"slickR",
"phateR",
"gelnet",
"parallelDist",
"kableExtra",
"transport",
"feather",
"markdown",
"ggalluvial",
"forcats",
"mcmc",
"MCMCpack",
"fields",
"getopt",
"osfr"))
```

- From GitHub
Expand Down Expand Up @@ -163,7 +164,7 @@ devtools::install_github(repo="ZhenyiWangTHU/HemaScopeR", dep = FALSE)
<!-- # stereopy==1.3.1 -->
<!-- ``` -->

## Create the required python virtual environment
## Create the required python (v.3.9.12) virtual environment

- Run the `init_miniconda` function to create the miniconda virtual environments for the scRNA-seq pipeline and ST pipeline of 10X Visium data and MERFISH data.

Expand Down
8 changes: 4 additions & 4 deletions _book/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<meta name="author" content="HemaScope team" />


<meta name="date" content="2024-10-17" />
<meta name="date" content="2024-10-22" />

<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="apple-mobile-web-app-capable" content="yes" />
Expand Down Expand Up @@ -145,9 +145,9 @@
<ul>
<li class="chapter" data-level="2.1" data-path="installation.html"><a href="installation.html#create-a-new-conda-environment-and-activate-it"><i class="fa fa-check"></i><b>2.1</b> Create a new conda environment and activate it</a></li>
<li class="chapter" data-level="2.2" data-path="installation.html"><a href="installation.html#set-the-channels-in-conda"><i class="fa fa-check"></i><b>2.2</b> Set the channels in conda</a></li>
<li class="chapter" data-level="2.3" data-path="installation.html"><a href="installation.html#install-r-and-python"><i class="fa fa-check"></i><b>2.3</b> Install R and python</a></li>
<li class="chapter" data-level="2.3" data-path="installation.html"><a href="installation.html#install-r"><i class="fa fa-check"></i><b>2.3</b> Install R</a></li>
<li class="chapter" data-level="2.4" data-path="installation.html"><a href="installation.html#install-required-r-packages"><i class="fa fa-check"></i><b>2.4</b> Install required R-packages</a></li>
<li class="chapter" data-level="2.5" data-path="installation.html"><a href="installation.html#create-the-required-python-virtual-environment"><i class="fa fa-check"></i><b>2.5</b> Create the required python virtual environment</a></li>
<li class="chapter" data-level="2.5" data-path="installation.html"><a href="installation.html#create-the-required-python-v.3.9.12-virtual-environment"><i class="fa fa-check"></i><b>2.5</b> Create the required python (v.3.9.12) virtual environment</a></li>
<li class="chapter" data-level="2.6" data-path="installation.html"><a href="installation.html#the-installed-packages-with-versions"><i class="fa fa-check"></i><b>2.6</b> The installed packages with versions</a></li>
</ul></li>
<li class="chapter" data-level="3" data-path="integrated-scrna-seq-pipeline.html"><a href="integrated-scrna-seq-pipeline.html"><i class="fa fa-check"></i><b>3</b> Integrated scRNA-seq pipeline</a></li>
Expand Down Expand Up @@ -348,7 +348,7 @@ <h1>
<div id="header">
<h1 class="title">HemaScope Tutorial</h1>
<p class="author"><em>HemaScope team</em></p>
<p class="date"><em>2024-10-17</em></p>
<p class="date"><em>2024-10-22</em></p>
</div>
<div id="introduction" class="section level1 hasAnchor" number="1">
<h1><span class="header-section-number">1</span> Introduction<a href="index.html#introduction" class="anchor-section" aria-label="Anchor link to header"></a></h1>
Expand Down
Loading

0 comments on commit cf18976

Please sign in to comment.