Skip to content

Commit e046b5d

Browse files
Exercise and Webpage update
1 parent cf9ef1b commit e046b5d

16 files changed

Lines changed: 2634 additions & 1141337 deletions

Notebooks-dev/00_instructions.ipynb

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,24 +10,28 @@
1010
"The present tutorial, like the rest of the course material, is available\n",
1111
"at our [open-source github\n",
1212
"repository](https://github.com/hds-sandbox/NGS_summer_course_Aarhus).\n",
13-
"\n",
14-
":::{.callout-tip collapse=\"true\" title=\"A few introductory points to run this notebook\"}\n",
1513
" \n",
16-
"* To use this notebook, use the `NGS (python)` kernel that contains the packages. Choose it by selecting `Kernel -> Change Kernel` in the menu on top of the window.\n",
14+
"* To use the notebooks in bash or python languages, use the `Python 3` kernel that contains the packages. For R notebooks use the `R` kernel. Choose it by selecting `Kernel -> Change Kernel` in the menu on top of the window.\n",
1715
"\n",
1816
"<figure>\n",
1917
"<img src=\"images/kernelchoice.png\" width=\"500\" alt=\"Kernel Choice\" class=\"center\">\n",
2018
"</figure>\n",
2119
"\n",
22-
"* In this notebook you will use only bash commands as you would do in the command line (this is why you read `%%bash` at the beginning of each piece of code). Those commands can be replicated in the command line, but we thought of integrating them in a notebook to make the tutorial understandable. The bash commands can also be marked with an `!` sign at the beginning of the line\n",
20+
"* In the very first notebook you will use only bash commands as you would do in the command line (this is why you read `%%bash` at the beginning of each piece of code). Those commands can be replicated in the command line, but we thought of integrating them in a notebook to make the tutorial understandable. The bash commands can also be marked with a `!` sign at the beginning of the line\n",
2321
"* On some computers, you might see the result of the commands once they are done running. This means you will wait some time while the computer is crunching, and only afterwards you will see the result of the command you have executed\n",
2422
"* You can run the code in each cell by clicking on the run cell button, or by pressing <kbd> Shift </kbd> + <kbd> Enter </kbd>. When the code is done running, a small green check sign will appear on the left side\n",
2523
"* You need to run the cells in sequential order, please do not run a cell until the one above finished running and do not skip any cells\n",
2624
"* Each cell contains a short description of the code and the output you should get. Please try not to focus on understanding the code for each command in too much detail, but rather try to focus on the output \n",
27-
"* You can create new code cells by pressing <kbd> + </kbd> in the Menu bar above. \n",
28-
" \n",
29-
":::"
25+
"* You can create new code cells by pressing <kbd> + </kbd> in the Menu bar above. "
3026
]
27+
},
28+
{
29+
"cell_type": "code",
30+
"execution_count": null,
31+
"id": "90df5da7-f5c7-4468-8fbe-c6b9dc2bc5f7",
32+
"metadata": {},
33+
"outputs": [],
34+
"source": []
3135
}
3236
],
3337
"metadata": {
@@ -47,6 +51,13 @@
4751
"nbconvert_exporter": "python",
4852
"pygments_lexer": "ipython3",
4953
"version": "3.11.0"
54+
},
55+
"widgets": {
56+
"application/vnd.jupyter.widget-state+json": {
57+
"state": {},
58+
"version_major": 2,
59+
"version_minor": 0
60+
}
5061
}
5162
},
5263
"nbformat": 4,

Notebooks-dev/01_raw_data_alignment.ipynb

Lines changed: 225 additions & 196 deletions
Large diffs are not rendered by default.

Notebooks-dev/02_VCF_variant_calling_analysis.ipynb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@
1212
" html:\n",
1313
" toc: true\n",
1414
"title: \"Variant calling and VCF files\"\n",
15-
"author: \"Lavinia I Fechete, Stig U Andersen, Mikkel H Schierup, Samuele Soraggi\"\n",
15+
"author: \"Lavinia Fechete, Samuele Soraggi, Stig U Andersen, Mikkel H Schierup\"\n",
16+
"date-modified: last-modified\n",
1617
"title-block-banner: true\n",
1718
"---"
1819
]

Notebooks-dev/03_bulk_RNA_analysis_edgeR.ipynb

Lines changed: 137 additions & 177 deletions
Large diffs are not rendered by default.

Notebooks-dev/04_scRNAseq_analysis.ipynb

Lines changed: 24 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
" toc: true\n",
2020
"title: \"Single cell analysis workflow\"\n",
2121
"author: \"Stig U Andersen, Mikkel H Schierup, Samuele Soraggi\"\n",
22+
"date-modified: last-modified\n",
2223
"title-block-banner: true\n",
2324
"---"
2425
]
@@ -40,28 +41,7 @@
4041
"- Merge datasets and do cross-data analysis\n",
4142
"\n",
4243
":::\n",
43-
"\n",
44-
"The present tutorial, like the rest of the course material, is available at our [open-source github repository](https://github.com/hds-sandbox/NGS_summer_course_Aarhus) and will be kept up-to-date as long as the course will be renewed.\n",
45-
"\n",
46-
"\n",
47-
"To use this notebook, use the `NGS (python)` kernel that contains the packages. Choose it by selecting `Kernel -> Change Kernel` in the menu on top of the window.\n",
48-
"\n",
49-
":::{.callout-tip collapse=\"true\" title=\"A few introductory points to run this notebook (click to show)\"}\n",
50-
" \n",
51-
"* To use this notebook, use the `NGS (Python)` kernel that contains the packages. Choose it by selecting `Kernel -> Change Kernel` in the menu on top of the window.\n",
52-
"\n",
53-
"<figure>\n",
54-
"<img src=\"images/kernelchoice.png\" width=\"500\" alt=\"Kernel Choice\" class=\"center\">\n",
55-
"</figure>\n",
56-
"\n",
57-
"* In this notebook you will use only python commands\n",
58-
"* On some computers, you might see the result of the commands once they are done running. This means you will wait some time while the computer is crunching, and only afterwards you will see the result of the command you have executed\n",
59-
"* You can run the code in each cell by clicking on the run cell button, or by pressing <kbd> Shift </kbd> + <kbd> Enter </kbd>. When the code is done running, a small green check sign will appear on the left side\n",
60-
"* You need to run the cells in sequential order, please do not run a cell until the one above finished running and do not skip any cells\n",
61-
"* Each cell contains a short description of the code and the output you should get. Please try not to focus on understanding the code for each command in too much detail, but rather try to focus on the output \n",
62-
"* You can create new code cells by pressing <kbd> + </kbd> in the Menu bar above. \n",
63-
" \n",
64-
":::"
44+
"\n"
6545
]
6646
},
6747
{
@@ -438461,7 +438441,6 @@
438461438441
" </figure>\n",
438462438442
"\n",
438463438443
":::{.callout-note}\n",
438464-
"\n",
438465438444
"Multiplets are in the almost totality of the cases doublets, because triplets and higher multiplets are extremely rare. We will thus talk only about doublets instead of multiplets. Read [this more technical blog post](https://liorpachter.wordpress.com/2019/02/07/sub-poisson-loading-for-single-cell-rna-seq/) for deeper explanations about this fact.\n",
438466438445
"\n",
438467438446
"As a rule of thumb, you can have a look [at this table](https://kb.10xgenomics.com/hc/en-us/articles/360059124751-Why-is-the-multiplet-rate-different-for-the-Next-GEM-Single-Cell-3-LT-v3-1-assay-compared-to-other-single-cell-applications-) to see what is the expected amount of doublets rate for different amounts of cells loaded in a single cell 10X experiment. In our case, each sample ranges somewhere between 3000 and 5000 cells, meaning there were somewhere between 8000 and 10000 loaded cells in each experiment (assuming efficiency of cell capture between 50% and 70%), so one could use 6-8% as a guess.\n",
@@ -438471,7 +438450,8 @@
438471438450
"<figcaption> Figure: doublet rates for various setting in a single cell experiment with 10X technology.</figcaption>\n",
438472438451
"</figure>\n",
438473438452
"\n",
438474-
"Below, we run the detection and obtain a score between 0 and 1 for each doublet. We will use that score for filtering"
438453+
"Below, we run the detection and obtain a score between 0 and 1 for each doublet. We will use that score for filtering\n",
438454+
":::"
438475438455
]
438476438456
},
438477438457
{
@@ -488755,10 +488735,10 @@
488755488735
"cell_type": "markdown",
488756488736
"metadata": {},
488757488737
"source": [
488758-
"### <div class=\"alert-success\"> <font size=\"+2\"> <b> Optional task </b> </font> </div>\n",
488738+
":::{.callout-tip title=Task}\n",
488759488739
"Try to look at other samples and see if there are some principal components highly dependent with technical features. You might also want to choose other technical features from the data.\n",
488760488740
"\n",
488761-
"The available samples are\n"
488741+
"The available samples are"
488762488742
]
488763488743
},
488764488744
{
@@ -488835,7 +488815,11 @@
488835488815
"cell_type": "markdown",
488836488816
"metadata": {},
488837488817
"source": [
488838-
"<div class=\"alert-success\"> <font size=\"+2\"> <b> End of optional task </b> </font> </div>"
488818+
":::\n",
488819+
"\n",
488820+
"**End of task**\n",
488821+
"\n",
488822+
"---"
488839488823
]
488840488824
},
488841488825
{
@@ -922723,8 +922707,7 @@
922723922707
"cell_type": "markdown",
922724922708
"metadata": {},
922725922709
"source": [
922726-
"### <div class=\"alert-success\"> <font size=\"+2\"> <b> Exercise: tSNE projection </b> </font> </div>\n",
922727-
"\n",
922710+
":::{.callout-tip title=\"tSNE projection}\n",
922728922711
"PCA and UMAP are two of the many projection methods available at the moment. Before UMAP, a very popular method was (and still is) tSNE [van der Maaten and Hinton, 2008](https://www.jmlr.org/papers/volume9/vandermaaten08a/vandermaaten08a.pdf). tSNE tries to match the statistical distribution of the high-dimensional data and its projection. The statistical distribution modeling high-dimensional data is Cryptoled by a parameter called *perplexity*, defining how far away cells are considered to be in the neighbourhood of a cell. The largest the perplexity, the farther away cells are going to be pulled close to each other in the tSNE projection. In general, tSNE is not very good at keeping the global behaviour of the data into account, while it often pulls cells together in separate chunks. \n",
922729922712
"\n",
922730922713
"Changing the perplexity can change a lot the output of tSNE, even though it has shown empirically being stable with values between 5 and 50.\n",
@@ -922832,7 +922815,11 @@
922832922815
"cell_type": "markdown",
922833922816
"metadata": {},
922834922817
"source": [
922835-
"--------------------"
922818+
":::\n",
922819+
"\n",
922820+
"**End of task**\n",
922821+
"\n",
922822+
"---"
922836922823
]
922837922824
},
922838922825
{
@@ -923380,7 +923367,7 @@
923380923367
"tags": []
923381923368
},
923382923369
"source": [
923383-
"### <div class=\"alert-success\"> <font size=\"+2\"> <b> Exercise: Gene Enrichment Analysis </b> </font> </div>\n"
923370+
":::{.callout-tip title=\"Task: Gene Enrichment Analysis\"}"
923384923371
]
923385923372
},
923386923373
{
@@ -923577,7 +923564,11 @@
923577923564
"source": [
923578923565
"Now paste the genes into the [Enrichr website](https://maayanlab.cloud/Enrichr/), then find possible interesting enriched terms.\n",
923579923566
"\n",
923580-
"------------"
923567+
":::\n",
923568+
"\n",
923569+
"**End of task**\n",
923570+
"\n",
923571+
"---"
923581923572
]
923582923573
},
923583923574
{
@@ -1141166,7 +1141157,7 @@
11411661141157
"name": "python",
11411671141158
"nbconvert_exporter": "python",
11411681141159
"pygments_lexer": "ipython3",
1141169-
"version": "3.11.7"
1141160+
"version": "3.11.0"
11411701141161
},
11411711141162
"toc-autonumbering": true,
11411721141163
"toc-showmarkdowntxt": false,

Notebooks/00_instructions.ipynb

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
{
2+
"cells": [
3+
{
4+
"cell_type": "markdown",
5+
"id": "d45d901e-a7c5-41c2-81aa-6bcd26ca6029",
6+
"metadata": {},
7+
"source": [
8+
"# Some instructions\n",
9+
"\n",
10+
"The present tutorial, like the rest of the course material, is available\n",
11+
"at our [open-source github\n",
12+
"repository](https://github.com/hds-sandbox/NGS_summer_course_Aarhus).\n",
13+
" \n",
14+
"* To use the notebooks in bash or python languages, use the `Python 3` kernel that contains the packages. For R notebooks use the `R` kernel. Choose it by selecting `Kernel -> Change Kernel` in the menu on top of the window.\n",
15+
"\n",
16+
"<figure>\n",
17+
"<img src=\"images/kernelchoice.png\" width=\"500\" alt=\"Kernel Choice\" class=\"center\">\n",
18+
"</figure>\n",
19+
"\n",
20+
"* In the very first notebook you will use only bash commands as you would do in the command line (this is why you read `%%bash` at the beginning of each piece of code). Those commands can be replicated in the command line, but we thought of integrating them in a notebook to make the tutorial understandable. The bash commands can also be marked with a `!` sign at the beginning of the line\n",
21+
"* On some computers, you might see the result of the commands once they are done running. This means you will wait some time while the computer is crunching, and only afterwards you will see the result of the command you have executed\n",
22+
"* You can run the code in each cell by clicking on the run cell button, or by pressing <kbd> Shift </kbd> + <kbd> Enter </kbd>. When the code is done running, a small green check sign will appear on the left side\n",
23+
"* You need to run the cells in sequential order, please do not run a cell until the one above finished running and do not skip any cells\n",
24+
"* Each cell contains a short description of the code and the output you should get. Please try not to focus on understanding the code for each command in too much detail, but rather try to focus on the output \n",
25+
"* You can create new code cells by pressing <kbd> + </kbd> in the Menu bar above. "
26+
]
27+
},
28+
{
29+
"cell_type": "code",
30+
"execution_count": null,
31+
"id": "90df5da7-f5c7-4468-8fbe-c6b9dc2bc5f7",
32+
"metadata": {},
33+
"outputs": [],
34+
"source": []
35+
}
36+
],
37+
"metadata": {
38+
"kernelspec": {
39+
"display_name": "Python 3 (ipykernel)",
40+
"language": "python",
41+
"name": "python3"
42+
},
43+
"language_info": {
44+
"codemirror_mode": {
45+
"name": "ipython",
46+
"version": 3
47+
},
48+
"file_extension": ".py",
49+
"mimetype": "text/x-python",
50+
"name": "python",
51+
"nbconvert_exporter": "python",
52+
"pygments_lexer": "ipython3",
53+
"version": "3.11.0"
54+
},
55+
"widgets": {
56+
"application/vnd.jupyter.widget-state+json": {
57+
"state": {},
58+
"version_major": 2,
59+
"version_minor": 0
60+
}
61+
}
62+
},
63+
"nbformat": 4,
64+
"nbformat_minor": 5
65+
}

0 commit comments

Comments
 (0)