Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Start wilms analysis #681

Merged
merged 49 commits into from
Aug 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
c1071c3
Create download-data.py
maud-p Jul 23, 2024
81c1712
create module 1
maud-p Jul 25, 2024
caddbbf
Update Dockerfile
maud-p Jul 25, 2024
c29e1cb
Update README.md
maud-p Jul 29, 2024
999d2f2
Update README.md
maud-p Jul 29, 2024
671d4d7
Add files via upload
maud-p Jul 29, 2024
ef22cb6
Update GeneticAlterations_metadata.csv
maud-p Jul 29, 2024
ab263d3
Update README.md
maud-p Jul 29, 2024
201bd53
Update README.md
maud-p Jul 29, 2024
3f7d64b
Update README.md
maud-p Jul 29, 2024
81e1478
Update README.md
maud-p Jul 29, 2024
b754e5d
changes to issue #671
maud-p Jul 30, 2024
b2a1167
Update analyses/cell-type-wilms-tumor-06/Dockerfile
maud-p Aug 1, 2024
b096507
Update analyses/cell-type-wilms-tumor-06/Dockerfile
maud-p Aug 1, 2024
89d8299
Update analyses/cell-type-wilms-tumor-06/README.md
maud-p Aug 1, 2024
e25c391
Update analyses/cell-type-wilms-tumor-06/README.md
maud-p Aug 1, 2024
97799c2
Update analyses/cell-type-wilms-tumor-06/README.md
maud-p Aug 1, 2024
85d4a09
Update analyses/cell-type-wilms-tumor-06/README.md
maud-p Aug 1, 2024
09e102b
Update Dockerfile
maud-p Aug 2, 2024
09de604
change inpu data
maud-p Aug 2, 2024
fa2d6a5
update_data_download_steps
maud-p Aug 2, 2024
38c1ae2
add sample metadata information
maud-p Aug 2, 2024
cbd6be3
remove unused mount directories
maud-p Aug 2, 2024
835b0c5
remove unused volumes
maud-p Aug 2, 2024
3adc01b
adding renv.lock file
maud-p Aug 2, 2024
9a2f1cf
Remove lock file (potentially temporarily!)
jaclyn-taroni Aug 3, 2024
6862fcc
Base image with RStudio that's compatible with ARM + renv
jaclyn-taroni Aug 3, 2024
83a6fe5
Commit output from renv::init()
jaclyn-taroni Aug 3, 2024
c4ec00a
Add an empty dependencies.R file
jaclyn-taroni Aug 3, 2024
4973f16
Add tidyverse to dependencies
jaclyn-taroni Aug 3, 2024
230bf62
Update lockfile after library(tidyverse)
jaclyn-taroni Aug 3, 2024
b4eebec
Uncomment renv steps from Dockerfile
jaclyn-taroni Aug 3, 2024
c4e64c1
Snapshot with some single-cell packages
jaclyn-taroni Aug 3, 2024
46c7e8b
renv::update()
jaclyn-taroni Aug 3, 2024
ebd2bf1
Stub in run workflow; don't uncomment on PR
jaclyn-taroni Aug 3, 2024
41bf440
Add Docker build and push for Wilms cell typing module
jaclyn-taroni Aug 3, 2024
afaff45
Add to list of modules with Docker images
jaclyn-taroni Aug 3, 2024
d3bce0e
Document experience with Docker and renv
jaclyn-taroni Aug 3, 2024
dd17e27
Remove files specific to Halbritter lab setup and stop tracking
jaclyn-taroni Aug 4, 2024
650df7b
Add newline
jaclyn-taroni Aug 4, 2024
47a84bc
Merge pull request #3 from jaclyn-taroni/jaclyn-taroni/wilms-06-build…
maud-p Aug 4, 2024
dca3199
Create run.sh
maud-p Aug 5, 2024
410ff39
DOI Correction
maud-p Aug 5, 2024
4d6e232
DOI Correction
maud-p Aug 5, 2024
5559521
Rename run.sh to run-podman-internal.sh
maud-p Aug 5, 2024
edd0e01
Update run-podman-internal.sh
maud-p Aug 5, 2024
3f6439b
Update analyses/cell-type-wilms-tumor-06/README.md
maud-p Aug 5, 2024
405730a
Update README.md halbritter specific section to run container
maud-p Aug 5, 2024
a71de56
Merge branch 'main' into start-wilms-analysis
jaclyn-taroni Aug 5, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/docker_all-modules.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
- simulate-sce
- cell-type-ewings
- doublet-detection
- cell-type-wilms-tumor-06
uses: ./.github/workflows/build-push-docker-module.yml
if: github.repository_owner == 'AlexsLemonade'
with:
Expand Down
55 changes: 55 additions & 0 deletions .github/workflows/docker_cell-type-wilms-tumor-06.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# This is a workflow to build the docker image for the cell-type-wilms-tumor-06 module
#
# Docker modules are run on pull requests when code for files that affect the Docker image have changed.
# If other files are used during the Docker build, they should be added to `paths`
#
# At module initialization, this workflow is inactive, and needs to be activated manually

name: Build docker image for cell-type-wilms-tumor-06

concurrency:
# only one run per branch at a time
group: "docker_cell-type-wilms-tumor-06_${{ github.ref }}"
cancel-in-progress: true

on:
pull_request:
branches:
- main
paths:
- "analyses/cell-type-wilms-tumor-06/Dockerfile"
- "analyses/cell-type-wilms-tumor-06/.dockerignore"
- "analyses/cell-type-wilms-tumor-06/renv.lock"
- "analyses/cell-type-wilms-tumor-06/conda-lock.yml"
workflow_dispatch:
inputs:
push-ecr:
description: "Push to AWS ECR"
type: boolean
required: true

jobs:
test-build:
name: Test Build Docker Image
if: github.event_name == 'pull_request' || (contains(github.event_name, 'workflow_') && !inputs.push-ecr)
runs-on: ubuntu-latest

steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Build image
uses: docker/build-push-action@v5
with:
context: "{{defaultContext}}:analyses/cell-type-wilms-tumor-06"
push: false
cache-from: type=gha
cache-to: type=gha,mode=max

build-push:
name: Build and Push Docker Image
if: github.repository_owner == 'AlexsLemonade' && (github.event_name == 'push' || inputs.push-ecr)
uses: ./.github/workflows/build-push-docker-module.yml
with:
module: "cell-type-wilms-tumor-06"
push-ecr: true
59 changes: 59 additions & 0 deletions .github/workflows/run_cell-type-wilms-tumor-06.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# This is a workflow to run the cell-type-wilms-tumor-06 module
#
# Analysis modules are run based on three triggers:
# - Manual trigger
# - On pull requests where code in the module has changed
# - As a reusable workflow called from a separate workflow which periodically runs all modules
#
# At initialization, only the manual trigger is active

name: Run cell-type-wilms-tumor-06 analysis module
env:
MODULE_PATH: analyses/cell-type-wilms-tumor-06
AWS_DEFAULT_REGION: us-east-2

concurrency:
# only one run per branch at a time
group: "run_cell-type-wilms-tumor-06_${{ github.ref }}"
cancel-in-progress: true

on:
workflow_dispatch:
# workflow_call:
# pull_request:
# branches:
# - main
# paths:
# - "analyses/cell-type-wilms-tumor-06/**"

jobs:
run-module:
if: github.repository_owner == 'AlexsLemonade'
runs-on: ubuntu-latest

steps:
- name: Checkout repo
uses: actions/checkout@v4

- name: Set up R
uses: r-lib/actions/setup-r@v2
with:
r-version: 4.4.0
use-public-rspm: true

- name: Set up pandoc
uses: r-lib/actions/setup-pandoc@v2

- name: Set up renv
uses: r-lib/actions/setup-renv@v2
with:
working-directory: ${{ env.MODULE_PATH }}

# Update this step as needed to download the desired data
- name: Download test data
run: ./download-data.py --test-data --format SCE

- name: Run analysis module
run: |
cd ${MODULE_PATH}
# run module script(s) here
4 changes: 4 additions & 0 deletions analyses/cell-type-wilms-tumor-06/.Rprofile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Don't activate renv in an OpenScPCA docker image
if(Sys.getenv('OPENSCPCA_DOCKER') != 'TRUE'){
source('renv/activate.R')
}
8 changes: 8 additions & 0 deletions analyses/cell-type-wilms-tumor-06/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Ignore everything by default
*

# Include specific files in the docker environment
!/renv.lock
!/requirements.txt
!/environment.yml
!/conda-lock.yml
11 changes: 11 additions & 0 deletions analyses/cell-type-wilms-tumor-06/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Results should not be committed
/results/*
!/results/README.md

# Ignore the scratch directory (but keep it present)
/scratch/*
!/scratch/.gitkeep

# Ignore Docker-related files specific to module author's system
config.yaml
run.sh
28 changes: 28 additions & 0 deletions analyses/cell-type-wilms-tumor-06/Dockerfile
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The workflow added with .github/workflows/docker_cell-type-wilms-tumor-06.yml passed: https://github.com/AlexsLemonade/OpenScPCA-analysis/actions/runs/10238728443/job/28323567327

So, now we can be confident that this builds successfully 🥳

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is a great news, thank you!!!
Should we wait a more complete Docker image before pushing it?
I would like to adapt the notebook with you comment (enrichment analysis of some gene sets) before filling the next pull request, with a docker image (renv.lock) that should be more complete.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's no need to wait – incremental changes are okay and expected! As you add R packages you need, I expect the renv.lock file to change, which means the Docker image will get rebuilt with the new R packages installed and pushed to ECR. That is to say that the workflow is set up to accommodate incremental changes!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

great !

Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Pull base image
# This image has RStudio Server on it
FROM bioconductor/bioconductor_docker:3.19

# Labels following the Open Containers Initiative (OCI) recommendations
# For more information, see https://specs.opencontainers.org/image-spec/annotations/?v=v1.0.1
LABEL org.opencontainers.image.title="openscpca/cell-type-wilms-tumor-06"
LABEL org.opencontainers.image.description="Docker image for the OpenScPCA analysis module 'cell-type-wilms-tumor-06'"
LABEL org.opencontainers.image.authors="OpenScPCA [email protected]"
LABEL org.opencontainers.image.source="https://github.com/AlexsLemonade/OpenScPCA-analysis/tree/main/analyses/cell-type-wilms-tumor-06"

# Set an environment variable to allow checking if we are in an OpenScPCA container
ENV OPENSCPCA_DOCKER=TRUE

# Disable the renv cache to install packages directly into the R library
ENV RENV_CONFIG_CACHE_ENABLED=FALSE

# Install renv
RUN R --no-echo --no-restore --no-save -e "install.packages('renv')"

# Copy the renv.lock file from the host environment to the image
COPY renv.lock renv.lock

# restore from renv.lock file and clean up to reduce image size
RUN Rscript -e 'renv::restore()' && \
rm -rf ~/.cache/R/renv && \
rm -rf /tmp/downloaded_packages && \
rm -rf /tmp/Rtmp*
180 changes: 180 additions & 0 deletions analyses/cell-type-wilms-tumor-06/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,180 @@
# Wilms Tumor Dataset Annotation (SCPCP000006)

Wilms tumor (WT) is the most common pediatric kidney cancer characterized by an exacerbated intra- and inter- tumor heterogeneity.
The genetic landscape of WT is very diverse in each of the histological contingents.
The COG classifies WT patients into two groups: the favorable histology and diffuse anaplasia.
Each of these groups is composed of the blastemal, epithelial, and stromal populations of cancer cells in different proportions, as well as cells from the normal kidney, mostly kidney epithelial cells, endothelial cells, immune cells and normal stromal cells (fibroblast).

## Description

Here, we first aim to annotate the Wilms Tumor snRNA-seq samples in the SCPCP000006 (n=40) dataset. To do so we will:

• Provide annotations of normal cells composing the kidney, including normal kidney epithelium, endothelium, stroma and immune cells
• Provide annotations of tumor cell populations that may be present in the WT samples, including blastemal, epithelial, and stromal populations of cancer cells
Based on the provided annotation, we would like to additionally provide a reference of marker genes for the three cancer cell populations, which is so far lacking for the WT community.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉


The analysis is/will be divided as the following:

- [x] Metadata file: compilation of a metadata file of marker genes for expected cell types that will be used for validation at a later step
- [ ] Script: clustering of cells across a set of parameters for few samples
- [ ] Script: label transfer from the fetal kidney atlas reference using runAzimuth
- [ ] Script: run InferCNV
- [ ] Notebook: explore results from steps 2 to 4 for about 5 to 10 samples
- [ ] Script: compile scripts 2 to 4 in a RMardown file with required adjustements and render it across all samples
- [ ] Notebook: explore results from step 6, integrate all samples together and annotate the dataset using (i) metadatafile, (ii) CNV information, (iii) label transfer information

## Usage
From Rstudio, run the Rmd reports or render the R scripts (see below R studio session set up).
You can also simply have a look at the html reports in the notebook folder.
Here, no need to run anything, we try to guide you through the analysis. Have a look at the code using the unhide code button on the top right of each chunk!

## Input files

### single nuclei data

We work with the _processed.rds SingleCellExperiment objects.
From the module directory, make sure that the conda environment is set-up:

```shell
conda activate openscpca
```

log into AWS CLI:
```shell
# replace `openscpca` with your AWS CLI profile name if it differs
export AWS_PROFILE=openscpca
aws sso login
```

use download-data.py to download the data as the following:
```shell
../../download-data.py --projects SCPCP000006
```
This is saving the data in OpenScPCA-analysis/data/current/SCPCP000006

Of note, this requires AWS CLI setup to run as intended: https://openscpca.readthedocs.io/en/latest/technical-setup/environment-setup/configure-aws-cli/

### sample metadata

The OpenScPCA-analysis/data/current/SCPCP000006/single_cell_metadata.tsv file contains clinical information related to the samples in the dataset.
Some information can be helpful for annotation and validation:

- treatment: Some of the samples have been pre-treated with chemotherapy and some are upfront resection.
We expect few changes between the 2 conditions, including a higher immune infiltration and more DNA damages pathways in treated samples.

- histology: the COG classifies Wilms tumor as either (i) Favorable or (ii) Anaplastic.
Some differenices are expected, some marker genes or pathways are associated with anaplasia (see sets of marker gene).

## Output files

## Marker sets

This folder is a resource for later validation of the annotated cell types.

### The table CellType_metadata.csv contains the following column and information:
- "gene_symbol" contains the symbol of the described gene, using the HUGO Gene Nomenclature
- ENSEMBL_ID contains the stable identifier from the ENSEMBL database
- cell_class is either "malignant" for marker genes specific to malignant population, or "non-malignant" for markers genes specific to non-malignant tissue or "both" for marker genes that can be found in malignant as well as non-malignant tissue but are still informative in respect to the cell type.
- cell_type contains the list of the cell types that are attributed to the marker gene
- DOI contains the list of main publication identifiers supporting the choice of the marker gene
- comment can be empty or contains any additional information

|gene_symbol|ENSEMBL_ID|cell_class|cell_type|DOI|comment|
|---|---|---|---|---|---|
|WT1|ENSG00000184937|malignant|cancer_cell|10.1242/dev.153163|Tumor_suppressor_WT1_is_lost_in_some_WT_cells|
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think of sc/snRNA-seq as better suited to picking up overexpression than loss. I know you've worked on these data before, so I'm just curious if you expect or have observed differences in WT1 expression in the cancer cells. Although, I see that you put:

WT1 (?)

in #635, so maybe we don't know yet!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added the (?) for the reason you mentionned, as we are looking for loss of function, I am not sure that we can really use it for annotation.

However, about 20% of Wilms tumor would have imperment of WT1, and I would expect the WT1 mutated Wilms tumor to have a specific transcriptional program. At the final step of integration of the 40 samples together, I would expect a cluster negative for WT1. Also, the normal kidney should be WT1 positive. So in this last step I think looking at WT1 would make sense.

|IGF2|ENSG00000167244|malignant|cancer_cell|10.1038/ng1293-408|NA|
|TP53|ENSG00000141510|malignant|anaplastic|10.1158/1078-0432.CCR-16-0985|Might_also_be_in_small_non_anaplastic_subset|
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From the abstract of this publication, I wonder if looking at TP53 loss/activation at a pathway level would be interesting 🤔

Copy link
Contributor Author

@maud-p maud-p Aug 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a great idea, I will implement this in the next PR:

  • Differential expression analysis using DElegate (pseudobulk based) FindAllMarkers2 to find markers for each clusters
  • Enrichment analysis of the markers genes, I was thinking using the gene sets hallmarks and MSigdB C8, I found them the most informative. The Hallmarks of Cancer might help us defining specific cancer clusters (proliferation +++, DNA damage/repair +++, hallmark TP53 in anaplastic Wilms tumor). And the MSigdB C8 can be an additionnal level of information regarding cell types. Do you think to some other gene sets?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

|MYCN|ENSG00000134323|malignant|anaplastic|10.18632/oncotarget.3377|Also_in_non_anaplastic_poor_outcome|
|MAX|ENSG00000125952|malignant|anaplastic|10.1016/j.ccell.2015.01.002|Also_in_non_anaplastic_poor_outcome|
|SIX1|ENSG00000126778|malignant|blastema|10.1016/j.ccell.2015.01.002|NA|
|SIX2|ENSG00000170577|malignant|blastema|10.1016/j.ccell.2015.01.002|NA|
Comment on lines +89 to +90
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to my TP53 comment – from a quick look at this publication, I wonder if looking at the altered expression patterns rather than the individual genes could be helpful.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the MSigdB C3/MIR gene sets, we have gene sets for DICER and DROSHA, I could also give a try to run enrichment for this dataset.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

|CITED1|ENSG00000125931|malignant|blastema|10.1593/neo.07358|Also_in_embryonic_kidney|
|PTPRC|ENSG00000081237|immune|NA|10.1101/gr.273300.120|NA|
|CD68|ENSG00000129226|immune|myeloid|10.1186/1746-1596-7-12|NA|
|CD163|ENSG00000177575|immune|macrophage|10.1186/1746-1596-7-12|NA|
|VWF|ENSG00000110799|endothelium|endothelium|10.1134/S1990747819030140|NA|
|CD3E|ENSG00000198851|immune|T_cell|10.1101/gr.273300.120|NA|
|MS4A1|ENSG00000156738|immune|B_cell|10.1101/gr.273300.120|NA|
|FOXP3|ENSG00000049768|immune|T_cell|10.1101/gr.273300.120|Treg|
|CD4|ENSG00000010610|immune|T_cell|10.1101/gr.273300.120|NA|
|CD8A|ENSG00000153563|immune|T_cell|10.1101/gr.273300.120|NA|
|EPCAM|ENSG00000119888|NA|epithelial|10.1016/j.stemcr.2014.05.013|epithelial_malignant_and_non_malignant|
|NCAM1|ENSG00000149294|malignant|blastema|10.1016/j.stemcr.2014.05.013|might_also_be_expressed_in_non_malignant|
|PODXL|ENSG00000128567|non-malignant|podocyte|10.1016/j.stem.2019.06.009|NA|
|COL6A3|ENSG00000163359|malignant|mesenchymal|10.2147/OTT.S256654|might_also_be_expressed_in_non_malignant_stroma|
|THY1|ENSG00000154096|malignant|mesenchymal|10.1093/hmg/ddq042|might_also_be_expressed_in_non_malignant_stroma|
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm curious why this gene differs from some of the ones outlined in the abstract and is included. I suppose I would not expect the ones outlined in the abstract to be specific to malignant cells necessarily.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unfortunately I don't know about one mesenchymal gene specific for mesenchymal Wilms tumor cells... For some colleagues who wanted to characterize CAF, the best approach I found was:

  1. identify stromal cells and
  2. based on the inferedCNV, distinguish normal from cancer stromal cells at the cluster level.

This is not perfect I think, but at least we should have clusters enriched in the target population.

Stromal cells are really easily identified based on either few markers, or label transfer from the fetal kidney reference. They often form one single cluster. This is the reason why I didn't spend too much time adding marker genes for them, but I can add few more mesenchymal markers and references for correctness :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • and THY1 is generally nicely expressed is I remember well!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd defer to you since you've spent more time thinking about this problem 😄

You don't need to add them – we'll have a record of this conversation!



### The table GeneticAlterations_metadata.csv contains the following column and information:
- alteration contains the number and portion of the affected chromosome
- gain_loss contains the information regarding the gain or loss of the corresponding genetic alteration
- cell_class is "malignant"
- cell_type contains the list of the malignant cell types that are attributed to the marker gene, either blastemal, stromal, epithelial or NA if none of the three histology is more prone to the described genetic alteration
- DOI contains the list of main publication identifiers supporting the choice of the genetic alteration
- comment can be empty or contains any additional information

|alteration|gain_loss|cell_class|cell_type|DOI|PMID|comment
|---|---|---|---|---|---|---|
|11p13|loss|malignant|NA|10.1242/dev.153163|NA|NA|
|11p15|loss|malignant|NA|10.1128/mcb.9.4.1799-1803.1989|NA|NA|
|16q|loss|malignant|NA|NA|1317258|Associated_with_relapse|
|1p|loss|malignant|NA|NA|8162576|Associated_with_relapse|
|1q|gain|malignant|NA|10.1016/S0002-9440(10)63982-X|NA|Associated_with_relapse|



## Software requirements

To perform the analysis, run the RMarkdown script in R (version 4.4.1).
The main packages used are:
- Seurat version 5
- Azimuth version 5
- inferCNV
- SCpubr for visualization
- DT for table visualization
- DElegate for differential expression analysis

### Docker

To build the Docker image, run the following from this directory:

```shell
docker buildx build . -t openscpca/cell-type-wilms-tumor-06
```

The image will also be available from ECR: <https://gallery.ecr.aws/openscpca/cell-type-wilms-tumor-06>

To run the container and develop in RStudio Server, run the following **from the root of the repository**, Replacing `{PASSWORD}`, including the curly braces, with a password of your choosing:

```shell
docker run \
--mount type=bind,target=/home/rstudio/OpenScPCA-analysis,source=$PWD \
-e PASSWORD={PASSWORD} \
-p 8787:8787 \
public.ecr.aws/openscpca/cell-type-wilms-tumor-06:latest
```

This will pull the latest version of the image from ECR if you do not yet have a copy locally.

Navigate to <http://localhost:8787/> and log in with the username `rstudio` and the password you set.

Within RStudio Server, `OpenScPCA-analysis` will point to your local copy of the repository.

#### A note on Apple Silicon

If you are on a Mac with an M series chip, you will not be able to use RStudio Server if you are using a `linux/amd64` or `linux/x86_84` (like the ones available from ECR).
You must build an ARM image locally to be able to use RStudio Server within the container.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add an H4 section here on Halbritter lab internal development please?

I'd expect that would include how to run the script (this is taking into account some review feedback):

./run-podman-internal.py {PASSWORD}

This hopefully helps you with your own development if, for example, you go on vacation for two weeks and come back to this! 😄 But it also helps others understand that this bash script isn't for their use.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll have to ask for some help in the Halbritter lab, add it on my to do list ;)

#### A note for Halbritter lab internal development
This work has been developed on a system that uses podman instead of docker. The steps to run the docker/podman images are slightly different and we saved in run-podman-internal.sh our internal approach to run the container. Please, refer to the Docker section to build and run the container instead.

### renv

This module uses `renv`.
If you are using RStudio Server within the container, the `renv` project will not be activated by default.
You can install packages within the container and use `renv::snapshot()` to update the lockfile without activating the project without a problem in our testing.
The `renv` lockfile is used to install R packages in the Docker image.

## Computational resources


8 changes: 8 additions & 0 deletions analyses/cell-type-wilms-tumor-06/components/dependencies.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Tidyverse
library(tidyverse)

# Single-cell packages
library(Seurat) # remotes::install_github("satijalab/[email protected]")
library(presto) # remotes::install_github("immunogenomics/presto")
library(Azimuth) # remotes::install_github("satijalab/azimuth")
library(SCpubr)
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
gene_symbol,ENSEMBL_ID,cell_class,cell_type,DOI,comment
WT1,ENSG00000184937,malignant,cancer_cell,10.1242/dev.153163,Tumor_suppressor_WT1_is_lost_in_some_WT_cells
IGF2,ENSG00000167244,malignant,cancer_cell,10.1038/ng1293-408,NA
TP53,ENSG00000141510,malignant,anaplastic,10.1158/1078-0432.CCR-16-0985,Might_also_be_in_small_non_anaplastic_subset
MYCN,ENSG00000134323,malignant,anaplastic,10.18632/oncotarget.3377,Also_in_non_anaplastic_poor_outcome
MAX,ENSG00000125952,malignant,anaplastic,10.1016/j.ccell.2015.01.002,Also_in_non_anaplastic_poor_outcome
SIX1,ENSG00000126778,malignant,blastema,10.1016/j.ccell.2015.01.002,NA
SIX2,ENSG00000170577,malignant,blastema,10.1016/j.ccell.2015.01.002,NA
CITED1,ENSG00000125931,malignant,blastema,10.1593/neo.07358,Also_in_embryonic_kidney
PTPRC,ENSG00000081237,immune,NA,10.1101/gr.273300.120,NA
CD68,ENSG00000129226,immune,myeloid,10.1186/1746-1596-7-12,NA
CD163,ENSG00000177575,immune,macrophage,10.1186/1746-1596-7-12,NA
VWF,ENSG00000110799,endothelium,endothelium,10.1134/S1990747819030140,NA
CD3E,ENSG00000198851,immune,T_cell,10.1101/gr.273300.120,NA
MS4A1,ENSG00000156738,immune,B_cell,10.1101/gr.273300.120,NA
FOXP3,ENSG00000049768,immune,T_cell,10.1101/gr.273300.120,Treg
CD4,ENSG00000010610,immune,T_cell,10.1101/gr.273300.120,NA
CD8A,ENSG00000153563,immune,T_cell,10.1101/gr.273300.120,NA
EPCAM,ENSG00000119888,NA,epithelial,10.1016/j.stemcr.2014.05.013,epithelial_malignant_and_non_malignant
NCAM1,ENSG00000149294,malignant,blastema,10.1016/j.stemcr.2014.05.013,might_also_be_expressed_in_non_malignant
PODXL,ENSG00000128567,non-malignant,podocyte,10.1016/j.stem.2019.06.009,NA
COL6A3,ENSG00000163359,malignant,mesenchymal,10.2147/OTT.S256654,might_also_be_expressed_in_non_malignant_stroma
THY1,ENSG00000154096,malignant,mesenchymal,10.1093/hmg/ddq042,might_also_be_expressed_in_non_malignant_stroma
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
alteration,gain_loss,cell_class,cell_type,DOI,PMID,comment
11p13,loss,malignant,NA,10.1242/dev.153163,NA,NA
11p15,loss,malignant,NA,10.1128/mcb.9.4.1799-1803.1989,NA,NA
16q,loss,malignant,NA,NA,1317258,Associated_with_relapse
1p,loss,malignant,NA,NA,8162576,Associated_with_relapse
1q,gain,malignant,NA,10.1016/S0002-9440(10)63982-X,NA,Associated_with_relapse
Empty file.
Loading