Add pedagogic content
1
.gitignore
vendored
@@ -9,3 +9,4 @@
|
||||
/web_src/**/*_files
|
||||
/web_src/**/*_cache
|
||||
/.luarc.json
|
||||
*.log
|
||||
862
fish-primers.qmd
Normal file
@@ -0,0 +1,862 @@
|
||||
---
|
||||
title: "Designing Fish primers"
|
||||
format: revealjs
|
||||
editor: visual
|
||||
---
|
||||
|
||||
```{r setup, include=FALSE}
|
||||
library(knitr)
|
||||
```
|
||||
|
||||
# Preparing the data
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## What do we need ?
|
||||
|
||||
To design a new animal DNA metabarcode we download from the NCBI the following data
|
||||
|
||||
- The complete set of whole mitochondrial genomes
|
||||
- The NCBI taxonomy
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## We need also:
|
||||
|
||||
- a Unix computer: a Mac or a Linux box
|
||||
- A unix terminal window for typing commands
|
||||
- Installed on the computer
|
||||
- The OBITools --- <http://github.com/metabarcoding/obitools4>
|
||||
- ecoPrimers --- <http://metabarcoding.org/ecoprimers>
|
||||
- R --- <http://wwww.r-project.org>
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Downloading the mitochondrial genomes
|
||||
|
||||
We can use an internet browser and download the files from NCBI FTP website
|
||||
|
||||
{fig-align="center"}
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Downloading the mitochondrial genomes
|
||||
|
||||
We can use an internet browser and download the files from NCBI FTP website
|
||||
|
||||
or run the following command lines
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
curl 'https://ftp.ncbi.nlm.nih.gov/genomes/refseq/mitochondrion/mitochondrion.1.genomic.gbff.gz' \
|
||||
> mito.all.gb.gz
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
zless mito.all.gb.gz
|
||||
```
|
||||
|
||||
```
|
||||
LOCUS NW_009243181 45189 bp DNA linear CON 06-OCT-2014
|
||||
DEFINITION Fonticula alba strain ATCC 38817 mitochondrial scaffold
|
||||
supercont2.211, whole genome shotgun sequence.
|
||||
ACCESSION NW_009243181 NZ_AROH01000000
|
||||
VERSION NW_009243181.1
|
||||
DBLINK BioProject: PRJNA262900
|
||||
Assembly: GCF_000388065.1
|
||||
KEYWORDS WGS; RefSeq.
|
||||
SOURCE mitochondrion Fonticula alba
|
||||
ORGANISM Fonticula alba
|
||||
Eukaryota; Rotosphaerida; Fonticulaceae; Fonticula.
|
||||
REFERENCE 1 (bases 1 to 45189)
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Downloading the complete taxonomy
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obitaxonomy --download-ncbi
|
||||
```
|
||||
|
||||
```
|
||||
INFO[0000] Number of workers set 16
|
||||
INFO[0000] Downloading NCBI Taxdump to ncbitaxo_20250211.tgz
|
||||
downloading 100% ████████████████████████████████████████| (66/66 MB, 5.1 MB/s)
|
||||
```
|
||||
|
||||
The NCBI taxonomy contains all the relationship between taxa. Each taxon is identified by a unique numerical id: `taxid`
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## The archive contains several files
|
||||
|
||||
file: `nodes.dmp`
|
||||
|
||||
```
|
||||
1 | 1 | no rank | | 8 | 0 | ...
|
||||
2 | 131567 | superkingdom | | 0 | 0 |
|
||||
6 | 335928 | genus | | 0 | 1 |
|
||||
7 | 6 | species | AC | 0 | 1 |
|
||||
9 | 32199 | species | BA | 0 |
|
||||
10 | 135621 | genus | | 0 |
|
||||
11 | 1707 | species | CG | 0 | 1 |
|
||||
13 | 203488 | genus | | 0 | 1 |
|
||||
14 | 13 | species | DT | 0 | 1 |
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## file: `names.dmp`
|
||||
|
||||
```
|
||||
1 | root | | scientific name |
|
||||
2 | Bacteria | Bacteria <prokaryote> | scientific name |
|
||||
2 | Monera | Monera <Bacteria> | in-part |
|
||||
2 | Procaryotae | Procaryotae <Bacteria> | in-part |
|
||||
2 | Prokaryota | Prokaryota <Bacteria> | in-part |
|
||||
2 | Prokaryotae | Prokaryotae <Bacteria> | in-part |
|
||||
2 | bacteria | bacteria <blast2> | blast name |
|
||||
2 | eubacteria | | genbank common name |
|
||||
2 | prokaryote | prokaryote <Bacteria> | in-part |
|
||||
...
|
||||
10 | Cellvibrio | | scientific name |
|
||||
11 | [Cellvibrio] gilvus | | scientific name |
|
||||
13 | Dictyoglomus | | scientific name |
|
||||
14 | Dictyoglomus thermophilum | | scientific name |
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Preparing the set of complete genomes
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obiconvert --skip-empty \
|
||||
--update-taxid \
|
||||
-t ncbitaxo_20250211.tgz \
|
||||
mito.all.gb.gz \
|
||||
> mito.all.fasta
|
||||
head -5 mito.all.fasta
|
||||
```
|
||||
|
||||
five first lines of the new `mito.all.fasta` file
|
||||
|
||||
```
|
||||
>NC_072933 {"definition":"Echinosophora koreensis mitochondrion, complete genome.","scientific_name":"mitochondrion Echinosophora koreensis","taxid":228658}
|
||||
ctttcgggtcggaaatagaagatctggattagatcccttctcgatagctttagtcagagc
|
||||
tcatccctcgaaaaagggagtagtgagatgagaaaagggtgactagaatacggaaattca
|
||||
actagtgaagtcagatccgggaattccactattgaagttatccgtcttaggcttcaagca
|
||||
agctatctttcaaggaagtcagtctaagccctaagccaagatctgctttttgccagtcaa
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## We want:
|
||||
|
||||
- annotate sequences by their species `taxid`
|
||||
- keep a single genome per species
|
||||
- extract only vertebrate genome
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Looking for the **Vertebrata**'s taxid
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obitaxonomy -t ncbitaxo_20250211.tgz \
|
||||
--fixed \
|
||||
'vertebrata'
|
||||
```
|
||||
|
||||
``` csv
|
||||
taxid,parent,taxonomic_rank,scientific_name
|
||||
taxon:1261581 [Vertebrata]@genus,taxon:2008651 [Polysiphonioideae]@subfamily,genus,Vertebrata
|
||||
taxon:7742 [Vertebrata]@clade,taxon:89593 [Craniata]@subphylum,clade,Vertebrata
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Looking for the **Vertebrata**'s taxid
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obitaxonomy -t ncbitaxo_20250211.tgz \
|
||||
--fixed \
|
||||
'vertebrata' \
|
||||
| csvlook
|
||||
```
|
||||
|
||||
``` csv
|
||||
| taxid | parent | taxonomic_rank | scientific_name |
|
||||
| -------------------------------- | ------------------------------------------- | -------------- | --------------- |
|
||||
| taxon:1261581 [Vertebrata]@genus | taxon:2008651 [Polysiphonioideae]@subfamily | genus | Vertebrata |
|
||||
| taxon:7742 [Vertebrata]@clade | taxon:89593 [Craniata]@subphylum | clade | Vertebrata |
|
||||
```
|
||||
|
||||
## A genus called **Vertebrata**
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obitaxonomy -t ncbitaxo_20250211.tgz \
|
||||
-p 2008651 \
|
||||
| csvlook
|
||||
```
|
||||
|
||||
``` csv
|
||||
| taxid | parent | taxonomic_rank | scientific_name |
|
||||
| ------------------------------------------- | ------------------------------------------- | -------------- | ------------------ |
|
||||
| taxon:2008651 [Polysiphonioideae]@subfamily | taxon:2803 [Rhodomelaceae]@family | subfamily | Polysiphonioideae |
|
||||
| taxon:2803 [Rhodomelaceae]@family | taxon:2802 [Ceramiales]@order | family | Rhodomelaceae |
|
||||
| taxon:2802 [Ceramiales]@order | taxon:2045261 [Rhodymeniophycidae]@subclass | order | Ceramiales |
|
||||
| taxon:2045261 [Rhodymeniophycidae]@subclass | taxon:2806 [Florideophyceae]@class | subclass | Rhodymeniophycidae |
|
||||
| taxon:2806 [Florideophyceae]@class | taxon:2763 [Rhodophyta]@phylum | class | Florideophyceae |
|
||||
| taxon:2763 [Rhodophyta]@phylum | taxon:2759 [Eukaryota]@superkingdom | phylum | Rhodophyta |
|
||||
| taxon:2759 [Eukaryota]@superkingdom | taxon:131567 [cellular organisms]@no rank | superkingdom | Eukaryota |
|
||||
| taxon:131567 [cellular organisms]@no rank | taxon:1 [root]@no rank | no rank | cellular organisms |
|
||||
| taxon:1 [root]@no rank | taxon:1 [root]@no rank | no rank | root |
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Reannotation and selection of the genomes
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obiannotate -t ncbitaxo_20250211.tgz \
|
||||
--with-taxon-at-rank=species \
|
||||
mito.all.fasta | \
|
||||
obiannotate -S 'ori_taxid=annotations.taxid' | \
|
||||
obiannotate -S 'taxid=annotations.species_taxid' | \
|
||||
obiuniq -c taxid > mito.one.fasta
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Species representation
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
|
||||
obicsv -k taxid mito.one.fasta \
|
||||
| tail -n +2 \
|
||||
| sort \
|
||||
| uniq -c \
|
||||
| sort -nk1 \
|
||||
| cut -w -f 2 \
|
||||
| uplot count
|
||||
```
|
||||
|
||||
```
|
||||
┌ ┐
|
||||
1 ┤■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■ 17769.0
|
||||
2 ┤ 90.0
|
||||
3 ┤ 17.0
|
||||
4 ┤ 5.0
|
||||
5 ┤ 4.0
|
||||
6 ┤ 2.0
|
||||
7 ┤ 1.0
|
||||
└ ┘
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Selection of the vertebrata genomes
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
|
||||
obigrep -t ncbitaxo_20250211.tgz \
|
||||
-r 7742 \
|
||||
mito.one.fasta > mito.vert.fasta
|
||||
```
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
|
||||
obicount mito.vert.fasta \
|
||||
| csvlook
|
||||
```
|
||||
|
||||
```
|
||||
| entities | n |
|
||||
| -------- | ----------- |
|
||||
| variants | 7,822 |
|
||||
| reads | 7,823 |
|
||||
| symbols | 131,378,756 |
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Prepare data for ecoPrimers 1/3
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
mkdir ncbitaxo_20250211
|
||||
cd ncbitaxo_20250211
|
||||
tar zxvf ../ncbitaxo_20250211.tgz
|
||||
cd ..
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Prepare data for ecoPrimers 2/3
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obiconvert -O mito.vert.fasta > mito.vert.old.fasta
|
||||
```
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
head -5 mito.vert.old.fasta
|
||||
```
|
||||
|
||||
``` csv
|
||||
>NC_071784 taxid=taxon:2065826 [Sineleotris saccharae]@species; count=1; ori_taxid=taxon:2065826 [Sineleotris saccharae]@species; scientific_name=mitochondrion Sineleotris saccharae; species_name=Sineleotris saccharae; species_taxid=taxon:2065826 [Sineleotris saccharae]@species; Sineleotris saccharae mitochondrion, complete genome.
|
||||
gctagcgtagcttaaccaaagcataacactgaagatgttaagatgggccctagaaagccc
|
||||
cgcaagcacaaaagcttggtcctggctttactatcagcttaggctaaacttacacatgca
|
||||
agtatccgcatccccgtgagaatgcccttaagctcccaccgctaacaggagtcaaggagc
|
||||
cggtatcaggcacaaccctgagttagcccacgacaccttgctcagccacacccccaaggg
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Prepare data for ecoPrimers 3/3
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
ecoPCRFormat -t ncbitaxo_20250211 \
|
||||
-f \
|
||||
-n vertebrata \
|
||||
mito.vert.old.fasta
|
||||
```
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
ls -l vertebrata*
|
||||
```
|
||||
|
||||
```
|
||||
-rw-r--r--@ 1 coissac staff 260899785 Feb 11 11:53 vertabrata.ndx
|
||||
-rw-r--r--@ 1 coissac staff 546 Feb 11 11:53 vertabrata.rdx
|
||||
-rw-r--r--@ 1 coissac staff 121379751 Feb 11 11:53 vertabrata.tdx
|
||||
-rw-r--r--@ 1 coissac staff 40446318 Feb 11 11:54 vertabrata_001.sdx
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Looking for the *Teleostei* `taxid`
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obitaxonomy -t ncbitaxo_20250211.tgz \
|
||||
--fixed \
|
||||
'Teleostei' \
|
||||
| csvlook
|
||||
```
|
||||
|
||||
``` csv
|
||||
| taxid | parent | taxonomic_rank | scientific_name |
|
||||
| ---------------------------------- | ---------------------------------- | -------------- | --------------- |
|
||||
| taxon:32443 [Teleostei]@infraclass | taxon:41665 [Neopterygii]@subclass | infraclass | Teleostei |
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Selecting the best primer pairs
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
ecoPrimers -d vertebrata \
|
||||
-e 3 -3 2 \
|
||||
-l 30 -L 150 \
|
||||
-r 32443 \
|
||||
-c > Teleostei.ecoprimers
|
||||
```
|
||||
|
||||
- Total pair count : 9407
|
||||
- Total good pair count : 407
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
head -35 Teleostei.ecoprimers
|
||||
```
|
||||
|
||||
``` csv
|
||||
#
|
||||
# ecoPrimer version 0.5
|
||||
# Rank level optimisation : species
|
||||
# max error count by oligonucleotide : 3
|
||||
#
|
||||
# Restricted to taxon:
|
||||
# 32443 : Teleostei (infraclass)
|
||||
#
|
||||
# strict primer quorum : 0.70
|
||||
# example quorum : 0.90
|
||||
# counterexample quorum : 0.10
|
||||
#
|
||||
# database : vertebrata
|
||||
# Database is constituted of 3909 examples corresponding to 3876 species
|
||||
# and 0 counterexamples corresponding to 0 species
|
||||
#
|
||||
# amplifiat length between [30,150] bp
|
||||
# DB sequences are considered as circular
|
||||
# Pairs having specificity less than 0.60 will be ignored
|
||||
#
|
||||
0 AGAGTGACGGGCGGTGTG CGTCAGGTCGAGGTGTAG 62.8 42.4 57.5 34.1 12 11 GG 3864 0 0.988 3832 0 0.989 2731 0.713 134 146 138.22
|
||||
1 CGTCAGGTCGAGGTGTAG GAGTGACGGGCGGTGTGT 57.5 34.1 63.1 42.9 11 12 GG 3863 0 0.988 3831 0 0.988 2730 0.713 133 145 137.22
|
||||
2 CGTCAGGTCGAGGTGTAG GGGAGAGTGACGGGCGGT 57.5 34.1 64.5 37.0 11 13 GG 3811 0 0.975 3779 0 0.975 2689 0.712 137 149 141.22
|
||||
3 CGTCAGGTCGAGGTGTAG GGGGAGAGTGACGGGCGG 57.5 34.1 65.5 38.4 11 14 GG 3804 0 0.973 3772 0 0.973 2682 0.711 138 149 142.22
|
||||
4 ACACCGCCCGTCACTCTC ACCTTCCGGTACACTTAC 62.5 36.8 54.0 16.6 12 9 GG 3850 0 0.985 3818 0 0.985 2658 0.696 46 132 66.51
|
||||
5 AACGTCAGGTCGAGGTGT AGAGTGACGGGCGGTGTG 58.8 28.4 62.8 41.7 10 12 GG 3779 0 0.967 3746 0 0.966 2653 0.708 137 148 140.23
|
||||
6 ACACCGCCCGTCACTCTC CACCTTCCGGTACACTTA 62.5 36.8 54.0 16.6 12 9 GG 3846 0 0.984 3814 0 0.984 2654 0.696 47 133 67.51
|
||||
7 AACGTCAGGTCGAGGTGT GAGTGACGGGCGGTGTGT 58.8 28.4 63.1 42.1 10 12 GG 3778 0 0.966 3745 0 0.966 2652 0.708 136 147 139.23
|
||||
8 ACCTTCCGGTACACTTAC CACACCGCCCGTCACTCT 54.0 16.6 62.8 37.3 9 12 GG 3845 0 0.984 3813 0 0.984 2653 0.696 47 133 67.51
|
||||
9 ACACCGCCCGTCACTCTC TCCGGTACACTTACCATG 62.5 36.8 54.1 18.1 12 9 GG 3851 0 0.985 3819 0 0.985 2651 0.694 42 128 62.51
|
||||
10 ACACCGCCCGTCACTCTC CCGGTACACTTACCATGT 62.5 36.8 54.4 18.6 12 9 GG 3851 0 0.985 3819 0 0.985 2651 0.694 41 127 61.51
|
||||
11 ACACCGCCCGTCACTCTC CCAAGTGCACCTTCCGGT 62.5 36.8 60.7 28.9 12 11 GG 3837 0 0.982 3805 0 0.982 2650 0.696 54 140 74.51
|
||||
12 ACACCGCCCGTCACTCTC GCACCTTCCGGTACACTT 62.5 36.8 57.7 22.5 12 10 GG 3842 0 0.983 3810 0 0.983 2650 0.696 48 134 68.51
|
||||
13 ACACCGCCCGTCACTCTC CGGTACACTTACCATGTT 62.5 36.8 52.4 15.7 12 8 GG 3850 0 0.985 3818 0 0.985 2650 0.694 40 126 60.51
|
||||
14 ACACCGCCCGTCACTCTC CACTTACCATGTTACGAC 62.5 36.8 51.1 27.7 12 8 GG 3850 0 0.985 3817 0 0.985 2649 0.694 35 121 55.51
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
- Primer ID : 11
|
||||
|
||||
|
||||
|
||||
| Primer | sequence | tm max | tm min | GC count |
|
||||
|---------|--------------------|--------|--------|----------|
|
||||
| Forward | ACACCGCCCGTCACTCTC | 62.5 | 36.8 | 12 |
|
||||
| Reverse | CCAAGTGCACCTTCCGGT | 60.7 | 28.9 | 11 |
|
||||
|
||||
|
||||
|
||||
- amplifying 3837/3909 sequences\
|
||||
- identify 2650/3876 Species
|
||||
- Size ranging from 54bp to 140bp (mean: 74.75 bp)
|
||||
|
||||
## Testing the new primer pair
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obipcr --forward ACACCGCCCGTCACTCTC \
|
||||
--reverse CCAAGTGCACCTTCCGGT \
|
||||
-e 5 \
|
||||
-l 30 -L 150 \
|
||||
-c \
|
||||
mito.vert.fasta \
|
||||
> Teleostei_11.fasta
|
||||
```
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
head Teleostei_11.fasta
|
||||
```
|
||||
|
||||
``` csv
|
||||
>NC_022183_sub[925..998] {"count":1,"definition":"Acrossocheilus hemispinus mitochondrion, complete genome.","direction":"forward","forward_error":1,"forward_match":"acaccgcccgtcaccctc","forward_primer":"ACACCGCCCGTCACTCTC","ori_taxid":"taxon:356810 [Acrossocheilus hemispinus]@species","reverse_error":0,"reverse_match":"ccaagtgcaccttccggt","reverse_primer":"CCAAGTGCACCTTCCGGT","scientific_name":"mitochondrion Acrossocheilus hemispinus","species_name":"Acrossocheilus hemispinus","species_taxid":"taxon:356810 [Acrossocheilus hemispinus]@species","taxid":"taxon:356810 [Acrossocheilus hemispinus]@species"}
|
||||
cccgtcaaaatacaccaaaaatacttaatacaataacactaacaaggggaggcaagtcgt
|
||||
aacatggtaagtgt
|
||||
>NC_018560_sub[916..988] {"count":1,"definition":"Astatotilapia calliptera mitochondrion, complete genome.","direction":"forward","forward_error":0,"forward_match":"acaccgcccgtcactctc","forward_primer":"ACACCGCCCGTCACTCTC","ori_taxid":"taxon:8154 [Astatotilapia calliptera]@species","reverse_error":1,"reverse_match":"ccaagtacaccttccggt","reverse_primer":"CCAAGTGCACCTTCCGGT","scientific_name":"mitochondrion Astatotilapia calliptera (eastern happy)","species_name":"Astatotilapia calliptera","species_taxid":"taxon:8154 [Astatotilapia calliptera]@species","taxid":"taxon:8154 [Astatotilapia calliptera]@species"}
|
||||
cccaagccaacaacatcctataaataatacattttaccggtaaaggggaggcaagtcgta
|
||||
acatggtaagtgt
|
||||
>NC_056117_sub[923..997] {"count":1,"definition":"Pseudocrossocheilus tridentis mitochondrion, complete genome.","direction":"forward","forward_error":0,"forward_match":"acaccgcccgtcactctc","forward_primer":"ACACCGCCCGTCACTCTC","ori_taxid":"taxon:887881 [Pseudocrossocheilus tridentis]@species","reverse_error":0,"reverse_match":"ccaagtgcaccttccggt","reverse_primer":"CCAAGTGCACCTTCCGGT","scientific_name":"mitochondrion Pseudocrossocheilus tridentis","species_name":"Pseudocrossocheilus tridentis","species_taxid":"taxon:887881 [Pseudocrossocheilus tridentis]@species","taxid":"taxon:887881 [Pseudocrossocheilus tridentis]@species"}
|
||||
ccctgtcaaaaagcatcaaatatatataataaattagcaatgacaaggggaggcaagtcg
|
||||
taacacggtaagtgt
|
||||
>NC_045904_sub[919..997] {"count":1,"definition":"Eospalax fontanierii mitochondrion, complete genome.","direction":"forward","forward_error":1,"forward_match":"acaccgcccgtcgctctc","forward_primer":"ACACCGCCCGTCACTCTC","ori_taxid":"taxon:146134 [Eospalax fontanierii]@species","reverse_error":4,"reverse_match":"ccaagcacactttccagt","reverse_primer":"CCAAGTGCACCTTCCGGT","scientific_name":"mitochondrion Eospalax fontanierii","species_name":"Eospalax fontanierii","species_taxid":"taxon:146134 [Eospalax fontanierii]@species","taxid":"taxon:146134 [Eospalax fontanierii]@species"}
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
convert the fasta file to csv
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obicsv --auto -s -i Teleostei_11.fasta > Teleostei_11.csv
|
||||
```
|
||||
|
||||
and display the begining of the table
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
head Teleostei_11.csv | csvlook
|
||||
```
|
||||
|
||||
``` csv
|
||||
| id | count | direction | forward_error | forward_match | forward_primer | ori_taxid | reverse_error | reverse_match | reverse_primer | scientific_name | species_name | species_taxid | taxid | sequence |
|
||||
| ------------------------- | ----- | --------- | ------------- | ------------------ | ------------------ | ---------------------------------------------------- | ------------- | ------------------ | ------------------ | ------------------------------------------------------ | ----------------------------- | ---------------------------------------------------- | ---------------------------------------------------- | ------------------------------------------------------------------------------- |
|
||||
| NC_022183_sub[925..998] | True | forward | True | acaccgcccgtcaccctc | ACACCGCCCGTCACTCTC | taxon:356810 [Acrossocheilus hemispinus]@species | 0 | ccaagtgcaccttccggt | CCAAGTGCACCTTCCGGT | mitochondrion Acrossocheilus hemispinus | Acrossocheilus hemispinus | taxon:356810 [Acrossocheilus hemispinus]@species | taxon:356810 [Acrossocheilus hemispinus]@species | cccgtcaaaatacaccaaaaatacttaatacaataacactaacaaggggaggcaagtcgtaacatggtaagtgt |
|
||||
| NC_018560_sub[916..988] | True | forward | False | acaccgcccgtcactctc | ACACCGCCCGTCACTCTC | taxon:8154 [Astatotilapia calliptera]@species | 1 | ccaagtacaccttccggt | CCAAGTGCACCTTCCGGT | mitochondrion Astatotilapia calliptera (eastern happy) | Astatotilapia calliptera | taxon:8154 [Astatotilapia calliptera]@species | taxon:8154 [Astatotilapia calliptera]@species | cccaagccaacaacatcctataaataatacattttaccggtaaaggggaggcaagtcgtaacatggtaagtgt |
|
||||
| NC_056117_sub[923..997] | True | forward | False | acaccgcccgtcactctc | ACACCGCCCGTCACTCTC | taxon:887881 [Pseudocrossocheilus tridentis]@species | 0 | ccaagtgcaccttccggt | CCAAGTGCACCTTCCGGT | mitochondrion Pseudocrossocheilus tridentis | Pseudocrossocheilus tridentis | taxon:887881 [Pseudocrossocheilus tridentis]@species | taxon:887881 [Pseudocrossocheilus tridentis]@species | ccctgtcaaaaagcatcaaatatatataataaattagcaatgacaaggggaggcaagtcgtaacacggtaagtgt |
|
||||
| NC_045904_sub[919..997] | True | forward | True | acaccgcccgtcgctctc | ACACCGCCCGTCACTCTC | taxon:146134 [Eospalax fontanierii]@species | 4 | ccaagcacactttccagt | CCAAGTGCACCTTCCGGT | mitochondrion Eospalax fontanierii | Eospalax fontanierii | taxon:146134 [Eospalax fontanierii]@species | taxon:146134 [Eospalax fontanierii]@species | ctcaagtacataaacttggatatattcttaataacccaacaaaaatattagaggagataagtcgtaacaaggtaagcat |
|
||||
| NC_018546_sub[916..987] | True | forward | False | acaccgcccgtcactctc | ACACCGCCCGTCACTCTC | taxon:30732 [Oryzias melastigma]@species | 0 | ccaagtgcaccttccggt | CCAAGTGCACCTTCCGGT | mitochondrion Oryzias melastigma (Indian medaka) | Oryzias melastigma | taxon:30732 [Oryzias melastigma]@species | taxon:30732 [Oryzias melastigma]@species | cccgacccattttaaaaattaaataaaagatttcaggaactaaggggaggcaagtcgtaacatggtaagtgt |
|
||||
| NC_044151_sub[922..993] | True | forward | False | acaccgcccgtcactctc | ACACCGCCCGTCACTCTC | taxon:2597641 [Sicyopterus squamosissimus]@species | 0 | ccaagtgcaccttccggt | CCAAGTGCACCTTCCGGT | mitochondrion Sicyopterus squamosissimus (cling goby) | Sicyopterus squamosissimus | taxon:2597641 [Sicyopterus squamosissimus]@species | taxon:2597641 [Sicyopterus squamosissimus]@species | cccaaaacaaacacacacataaataagaaaaaatgaaaataaaggggaggcaagtcgtaacatggtaagtgt |
|
||||
| NC_044152_sub[922..994] | True | forward | False | acaccgcccgtcactctc | ACACCGCCCGTCACTCTC | taxon:2597642 [Sicyopterus stiphodonoides]@species | 0 | ccaagtgcaccttccggt | CCAAGTGCACCTTCCGGT | mitochondrion Sicyopterus stiphodonoides (cling goby) | Sicyopterus stiphodonoides | taxon:2597642 [Sicyopterus stiphodonoides]@species | taxon:2597642 [Sicyopterus stiphodonoides]@species | cccaaaacaaacacacacataaataagaaaaaantgaaaataaaggggaggcaagtcgtaacatggtaagtgt |
|
||||
| NC_026976_sub[1453..1531] | True | forward | True | acaccgcccgtcactccc | ACACCGCCCGTCACTCTC | taxon:9545 [Macaca nemestrina]@species | 1 | ccaagtgcaccttccagt | CCAAGTGCACCTTCCGGT | mitochondrion Macaca nemestrina (pig-tailed macaque) | Macaca nemestrina | taxon:9545 [Macaca nemestrina]@species | taxon:9545 [Macaca nemestrina]@species | ctcaaatatatttaaggaacatcttaactaaacgccctaatatttatatagaggggataagtcgtaacatggtaagtgt |
|
||||
| NC_031553_sub[921..995] | True | forward | False | acaccgcccgtcactctc | ACACCGCCCGTCACTCTC | taxon:643337 [Puntioplites proctozystron]@species | 0 | ccaagtgcaccttccggt | CCAAGTGCACCTTCCGGT | mitochondrion Puntioplites proctozystron | Puntioplites proctozystron | taxon:643337 [Puntioplites proctozystron]@species | taxon:643337 [Puntioplites proctozystron]@species | ccctgtcaaaacgcactaaaaatatctaatacaaaagcaccgacaaggggaggcaagtcgtaacacggtaagtgt |
|
||||
```
|
||||
|
||||
# We are now switching to R
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Preparing our R session
|
||||
|
||||
First we have to download the two follong libraries
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
library(tidyverse)
|
||||
library(ggpubr)
|
||||
library(ROBITools4)
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Loading the data
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
|
||||
fish <- read_csv('Teleostei_11.csv', show_col_types = FALSE)
|
||||
taxo <- read_ncbi_taxdump('ncbitaxo_20250211')
|
||||
assign_default_taxonomy(taxo)
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
Looking for Teleostei taxid
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
teleo_taxid <- ecofind('Teleostei')
|
||||
teleo_taxid
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Format taxids
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
fish %>% mutate(
|
||||
taxid = as_taxid(
|
||||
as.integer(
|
||||
str_split_fixed(
|
||||
str_split_fixed(
|
||||
taxid,pattern = " ",
|
||||
n = 2)[,1],
|
||||
":",
|
||||
2)[,2]))
|
||||
) %>%
|
||||
as_tbl_obipcr() %>%
|
||||
mutate(across(taxon(),
|
||||
.names="category",
|
||||
.fn=taxonomy_classifier(Teleostei = 32443))) %>%
|
||||
group_by(category) %>%
|
||||
mutate(weight = taxonomic_weights(taxid,taxo)) %>%
|
||||
ungroup() -> fish
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## The fish tibble
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
head(fish,n = 4)
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Identifying which sequences belongs fish
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
table(fish$category)
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Testing the conservation of the priming sites
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
pssm_forward <- pssm(fish$forward_match,
|
||||
weights = fish$weight,
|
||||
categories = fish$category)
|
||||
|
||||
pssm_reverse <- pssm(fish$reverse_match,
|
||||
weights = fish$weight,
|
||||
categories = fish$category)
|
||||
```
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
pssm_forward
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Rescaling the matrix as Shanon entropy
|
||||
|
||||
$$
|
||||
H = - \sum_{i \in \{A,C,G,T\}} p_i \times \frac{\log(p_i)}{\log(2)}
|
||||
$$
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
pssm_forward <- pssm_scale_shanon(pssm_forward)
|
||||
pssm_reverse <- pssm_scale_shanon(pssm_reverse)
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Display the rescaled matrix
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
pssm_forward
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## The DNA logo of our primer pair
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
flogo <- ggbarcodelogo(pssm_forward) +
|
||||
xlab("Forward primer") + ylab("Bits")
|
||||
rlogo <- ggbarcodelogo(pssm_reverse) +
|
||||
xlab("Reverse primer") + ylab("Bits")
|
||||
|
||||
ggarrange(flogo,rlogo,ncol=2) -> dnaplot
|
||||
|
||||
dnaplot
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## How many mismatches ?
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
ggbarcodemistmatch(fish$forward_error,
|
||||
fish$reverse_error,
|
||||
otu=fish$species_name,
|
||||
categories=fish$category) + theme_minimal()
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Are we discriminate taxa ?
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
with(fish %>% filter(category == "Teleostei"),
|
||||
discriminated_at_rank(taxid,
|
||||
c("species","genus","family","order"),
|
||||
sequence))
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## How many sequences will provide information at rank ?
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
with(fish %>% filter(category == "Teleostei"),
|
||||
discriminant_at_rank(taxid,
|
||||
c("species","genus","family","order"),
|
||||
sequence))
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Is it the same for *Cyprinidae* ?
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
cyprinidae_taxid <- ecofind('Cyprinidae')
|
||||
cyprinidae_taxid
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Classify according to both categories
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
fish %>%
|
||||
mutate(across(taxon(),
|
||||
.names="category2",
|
||||
.fn=taxonomy_classifier(Teleostei = 32443,
|
||||
Cyprinidae = 7953))) -> fish
|
||||
|
||||
table(fish$category2)
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Are we discriminate taxa ?
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
with(fish %>% filter(category2 == "Cyprinidae"),
|
||||
discriminated_at_rank(taxid,
|
||||
c("species","genus"),
|
||||
sequence))
|
||||
```
|
||||
|
||||
# Go back to unix
|
||||
|
||||
## We run ecoPrimers and ecoPCR on the select primer pair
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
ecoPrimers -d vertebrata \
|
||||
-e 3 -3 2 \
|
||||
-l 30 -L 150 \
|
||||
-r 7953 -c > Cyprinidae.ecoprimers
|
||||
```
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obipcr --forward ACGGCGTAAAGGGTGGTT \
|
||||
--reverse TATCTAATCCCAGTTTGT \
|
||||
-e 5 \
|
||||
-l 30 -L 500 \
|
||||
-c \
|
||||
mito.vert.fasta \
|
||||
> Cyprinidae_14.fasta
|
||||
```
|
||||
|
||||
```{bash}
|
||||
#| eval: false
|
||||
#| echo: true
|
||||
obicsv --auto -s -i Cyprinidae_14.fasta > Cyprinidae_14.csv
|
||||
```
|
||||
|
||||
# Go back to R
|
||||
|
||||
```{r}
|
||||
cyprinidae <- read_csv('Cyprinidae_14.csv',
|
||||
show_col_types = FALSE) %>%
|
||||
mutate(
|
||||
taxid = as_taxid(
|
||||
as.integer(
|
||||
str_split_fixed(
|
||||
str_split_fixed(
|
||||
taxid,pattern = " ",
|
||||
n = 2)[,1],
|
||||
":",
|
||||
2)[,2]))
|
||||
) %>%
|
||||
as_tbl_obipcr() %>%
|
||||
mutate(across(taxon(),
|
||||
.names="category",
|
||||
.fn=taxonomy_classifier(Teleostei = 32443,
|
||||
Cyprinidae = 7953))) %>%
|
||||
group_by(category) %>%
|
||||
mutate(weight = taxonomic_weights(taxid,taxo)) %>%
|
||||
ungroup()
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Identifying which sequences belongs fish and *Cyprinidae*
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
table(cyprinidae$category)
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Looking for conservation
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
pssm_forward <- pssm(cyprinidae$forward_match,
|
||||
weights = cyprinidae$weight,
|
||||
categories = cyprinidae$category) %>%
|
||||
pssm_scale_shanon()
|
||||
|
||||
pssm_reverse <- pssm(cyprinidae$reverse_match,
|
||||
weights = cyprinidae$weight,
|
||||
categories = cyprinidae$category) %>%
|
||||
pssm_scale_shanon()
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Plot the new DNA logo
|
||||
|
||||
```{r}
|
||||
flogo <- ggbarcodelogo(pssm_forward) +
|
||||
xlab("Forward primer") + ylab("Bits")
|
||||
rlogo <- ggbarcodelogo(pssm_reverse) +
|
||||
xlab("Reverse primer") + ylab("Bits")
|
||||
|
||||
ggarrange(flogo,rlogo,ncol=2) -> dnaplot
|
||||
|
||||
dnaplot
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## How many mismatches ?
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
ggbarcodemistmatch(cyprinidae$forward_error,
|
||||
cyprinidae$reverse_error,
|
||||
otu=cyprinidae$species_name,
|
||||
categories=cyprinidae$category) + theme_minimal()
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
## Are we discriminate *Cyprinidae* taxa ?
|
||||
|
||||
```{r}
|
||||
#| echo: true
|
||||
with(cyprinidae %>% filter(category == "Cyprinidae"),
|
||||
discriminated_at_rank(taxid,
|
||||
c("species","genus"),
|
||||
sequence))
|
||||
```
|
||||
1227
jupyterhub_volumes/course/biodiversity_metrics_exercises.ipynb
Normal file
@@ -2,128 +2,883 @@
|
||||
"cells": [
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "30438c30",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"# Unix Essentials — Bash Exercises\n",
|
||||
"# Unix Essentials — Bash Practice Notebook\n",
|
||||
"\n",
|
||||
"This notebook contains short hands-on Bash exercises.\n",
|
||||
"Each exercise has a hidden solution that can be unfolded when needed."
|
||||
"This notebook contains 50 small Bash exercises grouped by topic.\n",
|
||||
"Each exercise includes a hidden solution that can be revealed in Jupyter."
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "39d711f9",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Exercise 1 – Listing and Filtering Files\n",
|
||||
"\n",
|
||||
"Create three files and list only those whose name ends with `.log`."
|
||||
"## Series 1 — Paths and Directories"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "6fb7335e",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 1.1 — Show your current working directory"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "2b8575f3",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"touch report.log notes.txt errors.log\n",
|
||||
"# list files ending with .log"
|
||||
"pwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "21f63bb0",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"source_hidden": true,
|
||||
"outputs_hidden": true
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"ls *.log"
|
||||
"pwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "61a624bf",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Exercise 2 – Redirecting Output\n",
|
||||
"\n",
|
||||
"List the `/etc` directory and save the results in a file named `listing.txt`, then display the first five lines of that file."
|
||||
"### Exercise 1.2 — Create a new directory named `testdir`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "4a4df387",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"# 1. list /etc\n",
|
||||
"# 2. redirect output to listing.txt\n",
|
||||
"# 3. show first five lines"
|
||||
"mkdir testdir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "2b5cfbca",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"source_hidden": true,
|
||||
"outputs_hidden": true
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"ls /etc > listing.txt\n",
|
||||
"head -5 listing.txt"
|
||||
"mkdir testdir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "2dccbb61",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Exercise 3 – Using a For Loop\n",
|
||||
"\n",
|
||||
"Write a loop that prints the line count of each `.txt` file in the current directory."
|
||||
"### Exercise 1.3 — Move into `testdir` using a relative path"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "fb73ca3c",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"# hint: use wc -l"
|
||||
"cd testdir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "ba670a20",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"source_hidden": true,
|
||||
"outputs_hidden": true
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"for f in *.txt; do\n",
|
||||
" echo \"$f: $(wc -l < \"$f\") lines\"\n",
|
||||
"done"
|
||||
"cd testdir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "4f7e5817",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"---\n",
|
||||
"All solutions are hidden by default (`source_hidden: true`). Students can unfold them in Jupyter’s interface to compare with their own answers."
|
||||
"### Exercise 1.4 — Create two subdirectories `a` and `b` in one command"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "30be8f44",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"mkdir a b"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "caf92714",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"mkdir a b"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "edec9041",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 1.5 — Return to the parent directory using `..`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "32a0f1df",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"cd .."
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "2a0aa92f",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"cd .."
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "31917159",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 1.6 — Create nested directories `one/two/three` in a single command"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "c0a313c3",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"mkdir -p one/two/three"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "4af63dce",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"mkdir -p one/two/three"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "24ee949e",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 1.7 — List the absolute path of the current directory"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "8258fff7",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"pwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "a6a062b2",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"pwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "6d724d3e",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 1.8 — Create a directory using an absolute path"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "5f497f7c",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"mkdir /tmp/mydir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "1d1d4e27",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"mkdir /tmp/mydir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "0a4cbe5b",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 1.9 — Display both `.` and `..` directories with `ls -a`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "7d962a9f",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"ls -a"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "91994de2",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"ls -a"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "e147ff34",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 1.10 — Remove the directory `/tmp/mydir`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "dcae28e3",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# your work here\n",
|
||||
"rmdir /tmp/mydir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "1a000f14",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"rmdir /tmp/mydir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "578548f7",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Series 2 — File Manipulation"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "813140d5",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 2.1 — Create an empty file named `notes.txt`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "08385872",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"touch notes.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "a474ad37",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"touch notes.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "6e918f3d",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 2.2 — Copy `notes.txt` to `backup.txt`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "faf85985",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"cp notes.txt backup.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "4d3e54d5",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"cp notes.txt backup.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "2c924f2e",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 2.3 — Rename `backup.txt` to `archive.txt`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "2d4adeb4",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"mv backup.txt archive.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "2c62e70f",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"mv backup.txt archive.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "c9e525a7",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 2.4 — Create 3 files and remove one with `rm`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "3ef53a3a",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"touch a.txt b.txt c.txt\n",
|
||||
"rm b.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "55e07074",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"touch a.txt b.txt c.txt\n",
|
||||
"rm b.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "b5a406b4",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 2.5 — Remove a directory recursively"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "2c819a49",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"mkdir -p tmpdir/sub\n",
|
||||
"rm -rf tmpdir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "b958a668",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"mkdir -p tmpdir/sub\n",
|
||||
"rm -rf tmpdir"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "9aa4996e",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Series 3 — Redirections and Pipes"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "ada90797",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 3.1 — Save the output of `ls` to a file `list.txt`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "25afa75b",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"ls > list.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "80ca4767",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"ls > list.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "61c3bff6",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 3.2 — Append the date to `list.txt`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "b7849f15",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"date >> list.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "83b08fe6",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"date >> list.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "600edcaa",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 3.3 — Count lines of `list.txt` with a pipe"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "37e859f4",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"cat list.txt | wc -l"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "d1429a1c",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"cat list.txt | wc -l"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "a901cf34",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 3.4 — Redirect error messages to a file"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "f2c1d530",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"ls /fakepath 2> errors.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "66c68bc4",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"ls /fakepath 2> errors.txt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "72e5eca4",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Series 4 — Viewing Results"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "dd7cbf2e",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 4.1 — Display the first 5 lines of `/etc/passwd`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "195c0f25",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"head -5 /etc/passwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "72dc0297",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"head -5 /etc/passwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "227ebdf8",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 4.2 — Show the last 3 lines of `/etc/passwd`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "3a829074",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"tail -3 /etc/passwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "e66f1752",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"tail -3 /etc/passwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "826cbb41",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 4.3 — Use `grep` to show lines containing 'root'"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "df9a877b",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"grep root /etc/passwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "5ed43d3d",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"grep root /etc/passwd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "a6c2f0a8",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Series 5 — Process Management"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "333ab7c1",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 5.1 — List current processes"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "41dc9dfb",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"ps"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "c0f28455",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"ps"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "c2d37e8f",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"### Exercise 5.2 — Display dynamic process list with `top`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "7931c9aa",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"top"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "947570cf",
|
||||
"metadata": {
|
||||
"jupyter": {
|
||||
"outputs_hidden": true,
|
||||
"source_hidden": true
|
||||
}
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
"top"
|
||||
]
|
||||
}
|
||||
],
|
||||
|
||||
1560
jupyterhub_volumes/course/unix_exercises_bash.ipynb
Normal file
@@ -2,9 +2,11 @@
|
||||
title: "Regular Expressions"
|
||||
format:
|
||||
revealjs:
|
||||
theme: beige # thème des slides
|
||||
css: ../../slides.css
|
||||
transition: fade # effet de transition entre les slides
|
||||
transition: slide
|
||||
scrollable: true
|
||||
theme: beige
|
||||
html-math-method: mathjax
|
||||
---
|
||||
|
||||
|
||||
|
Before Width: | Height: | Size: 9.6 KiB After Width: | Height: | Size: 9.6 KiB |
|
Before Width: | Height: | Size: 6.5 KiB After Width: | Height: | Size: 6.5 KiB |
|
Before Width: | Height: | Size: 146 KiB After Width: | Height: | Size: 146 KiB |
|
Before Width: | Height: | Size: 110 KiB After Width: | Height: | Size: 110 KiB |
|
Before Width: | Height: | Size: 2.5 KiB After Width: | Height: | Size: 2.5 KiB |
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
|
Before Width: | Height: | Size: 155 KiB After Width: | Height: | Size: 155 KiB |
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
|
Before Width: | Height: | Size: 54 KiB After Width: | Height: | Size: 54 KiB |
|
Before Width: | Height: | Size: 29 KiB After Width: | Height: | Size: 29 KiB |
|
Before Width: | Height: | Size: 31 KiB After Width: | Height: | Size: 31 KiB |
|
Before Width: | Height: | Size: 23 KiB After Width: | Height: | Size: 23 KiB |
|
Before Width: | Height: | Size: 31 KiB After Width: | Height: | Size: 31 KiB |
|
Before Width: | Height: | Size: 4.6 KiB After Width: | Height: | Size: 4.6 KiB |
|
Before Width: | Height: | Size: 3.4 KiB After Width: | Height: | Size: 3.4 KiB |
|
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 2.9 KiB |
|
Before Width: | Height: | Size: 4.0 KiB After Width: | Height: | Size: 4.0 KiB |
|
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 4.4 KiB |
|
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 4.5 KiB |
|
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 4.5 KiB |
|
Before Width: | Height: | Size: 265 KiB After Width: | Height: | Size: 265 KiB |
|
Before Width: | Height: | Size: 198 KiB After Width: | Height: | Size: 198 KiB |
|
Before Width: | Height: | Size: 231 KiB After Width: | Height: | Size: 231 KiB |
|
Before Width: | Height: | Size: 18 KiB After Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 5.3 KiB After Width: | Height: | Size: 5.3 KiB |
|
Before Width: | Height: | Size: 86 KiB After Width: | Height: | Size: 86 KiB |
|
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 4.4 KiB |
|
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 12 KiB |
@@ -6,12 +6,11 @@ title: |
|
||||
author: frederic.boyer@univ-grenoble-alpes.fr
|
||||
format:
|
||||
revealjs:
|
||||
theme: beige
|
||||
css: ../../slides.css
|
||||
transition: fade
|
||||
width: 1280
|
||||
height: 720
|
||||
center: true
|
||||
transition: slide
|
||||
scrollable: true
|
||||
theme: beige
|
||||
html-math-method: mathjax
|
||||
---
|
||||
|
||||
# Introduction to Unix
|
||||
1248
web_src/05_Lectures/05_Metabarcoding/Biodiversity_indices/Slides.qmd
Normal file
@@ -0,0 +1,167 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg width="100%" height="100%" viewBox="0 0 2031 2071" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linecap:square;stroke-linejoin:round;stroke-miterlimit:1.41421;">
|
||||
<g transform="matrix(1,0,0,1,-192,-982)">
|
||||
<g id="Main-Plot">
|
||||
<g>
|
||||
<g id="Grille">
|
||||
<g transform="matrix(1.1808,0,0,1,-75.4118,0)">
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,-172.262)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,975.279)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,811.344)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,647.41)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,1303.15)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,319.541)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,155.607)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,-8.32717)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,1139.21)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,483.476)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(3.34494e-16,1.1808,-1,2.83277e-16,3205.71,544.557)">
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,-172.262)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,975.279)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,811.344)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,647.41)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,1303.15)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,319.541)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,155.607)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,-8.32717)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,1139.21)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1.31073,-19.234,483.476)">
|
||||
<path d="M436.328,1027.97L1919.68,1027.97" style="fill:none;stroke-width:50.1px;stroke:rgb(181,181,181);"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="Manhattan-distance">
|
||||
<g transform="matrix(1.01074,0,0,1.02216,-24.6851,-56.3204)">
|
||||
<clipPath id="_clip1">
|
||||
<path d="M1863.49,1501.96L718.479,1502.83L720.193,2321.91"/>
|
||||
</clipPath>
|
||||
<g clip-path="url(#_clip1)">
|
||||
<g transform="matrix(0.989373,0,0,0.978321,24.4228,55.0994)">
|
||||
<path d="M731.553,2320.07L1041.96,2321.26L1869.39,1502.84" style="fill:none;stroke-width:20.83px;stroke:rgb(239,159,75);"/>
|
||||
</g>
|
||||
</g>
|
||||
<path d="M1863.49,1501.96L718.479,1502.83L720.193,2321.91" style="fill:none;stroke-width:20.5px;stroke:rgb(239,159,75);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,-8.23449,-149.065)">
|
||||
<path d="M745.363,2464.19L745.61,1981.62L894.445,1981.51L893.831,1816.25L1221.66,1817.42L1222.61,1674.94L1870.55,1673.53" style="fill:none;stroke-width:20.83px;stroke:rgb(239,159,75);"/>
|
||||
</g>
|
||||
</g>
|
||||
<g id="Euclidean-distance" transform="matrix(0.703395,-0.510486,0.510486,0.703395,-942.486,881.423)">
|
||||
<g transform="matrix(-1.21281,-1.91042e-15,-5.1683e-15,18.1142,3042.18,-42457.3)">
|
||||
<path d="M723.133,2480.78L2039.58,2480.04" style="fill:none;stroke-width:1.87px;stroke:rgb(31,146,28);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.73227,-8.453e-16,7.24543e-16,1.73227,700.347,-1893.39)">
|
||||
<text x="183.268px" y="2487.83px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Euclidean distance</text>
|
||||
</g>
|
||||
<g transform="matrix(1.40197,1.01747,-1.01747,1.40197,3635.4,-1896.41)">
|
||||
<text x="183.268px" y="2487.83px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Manhattan distance</text>
|
||||
</g>
|
||||
<g transform="matrix(1.70572,-0.302138,0.302138,1.70572,92.3532,-1423.68)">
|
||||
<text x="183.268px" y="2487.83px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Chebyshev distance</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,-7.03869,-1.75967)">
|
||||
<path d="M1869.12,1514.53L1052.81,2325.83L741.235,2322.67" style="fill:none;stroke-width:20.83px;stroke-linecap:butt;stroke:rgb(201,0,157);"/>
|
||||
</g>
|
||||
<g id="Point-B" transform="matrix(1,0,0,1,330.868,1784.29)">
|
||||
<g transform="matrix(1,0,0,1,2.98908,0)">
|
||||
<ellipse cx="381.618" cy="545.025" rx="28.788" ry="32.295" style="fill:rgb(235,235,235);stroke-width:62.5px;stroke:rgb(0,19,255);"/>
|
||||
</g>
|
||||
<g transform="matrix(2.92627,0,0,2.04123,-334.325,-1052.74)">
|
||||
<text x="229.007px" y="733.807px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">A</text>
|
||||
</g>
|
||||
</g>
|
||||
<g id="Point-B1" transform="matrix(1,0,0,1,1080.14,962.633)">
|
||||
<g transform="matrix(1,0,0,1,402.614,0)">
|
||||
<ellipse cx="381.618" cy="545.025" rx="28.788" ry="32.295" style="fill:rgb(235,235,235);stroke-width:62.5px;stroke:rgb(255,0,6);"/>
|
||||
</g>
|
||||
<g transform="matrix(2.92627,0,0,2.04123,65.3005,-1052.74)">
|
||||
<text x="229.007px" y="733.807px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">B</text>
|
||||
</g>
|
||||
</g>
|
||||
<g id="Coordinates">
|
||||
<g id="B">
|
||||
<g id="Xb">
|
||||
<g id="Xb1" transform="matrix(1.40046e-16,-2.28712,1,6.12323e-17,-458.914,3473.11)">
|
||||
<path d="M254.53,2321.59L898.365,2321.59" style="fill:none;stroke-width:5.9px;stroke-linecap:butt;stroke-dasharray:5.9,5.9,5.9,0;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(20.9725,0,1.97215e-31,20.9725,-12015.1,-59666.6)">
|
||||
<text x="658.77px" y="2988.33px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:6.548px;fill:black;">x</text>
|
||||
<text x="662.044px" y="2990.51px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:3.817px;fill:black;">B</text>
|
||||
</g>
|
||||
</g>
|
||||
<g id="Yb">
|
||||
<g id="Yb1" transform="matrix(2.53289,0,0,0.949467,-314.832,-697.08)">
|
||||
<path d="M254.53,2321.59L898.365,2321.59" style="fill:none;stroke-width:5.45px;stroke-linecap:butt;stroke-dasharray:5.45,5.45,5.45,0;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(20.9725,0,1.97215e-31,20.9725,-13626.2,-61124.7)">
|
||||
<text x="658.77px" y="2988.33px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:6.548px;fill:black;">y</text>
|
||||
<text x="662.044px" y="2990.51px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:3.817px;fill:black;">B</text>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="A">
|
||||
<g id="Ya">
|
||||
<g id="Ya1" transform="matrix(0.865442,-6.16298e-33,0,1,109.585,4.54747e-13)">
|
||||
<path d="M254.53,2321.59L898.365,2321.59" style="fill:none;stroke-width:11.14px;stroke-linecap:butt;stroke-dasharray:11.14,11.14,11.14,0;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(20.9725,0,0,20.9725,-13626.2,-60326.8)">
|
||||
<text x="658.77px" y="2988.33px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:6.548px;fill:black;">y</text>
|
||||
<text x="662.044px" y="2990.51px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:3.817px;fill:black;">A</text>
|
||||
</g>
|
||||
</g>
|
||||
<g id="Xa">
|
||||
<g id="Xa1" transform="matrix(6.08856e-17,-0.994338,1,6.12323e-17,-1605.05,3144.05)">
|
||||
<path d="M254.53,2321.59L898.365,2321.59" style="fill:black;stroke-width:10.45px;stroke-linecap:butt;stroke-dasharray:10.45,10.45,10.45,0;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(20.9725,0,0,20.9725,-13160.4,-59666.6)">
|
||||
<text x="658.77px" y="2988.33px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:6.548px;fill:black;">x</text>
|
||||
<text x="662.044px" y="2990.51px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:3.817px;fill:black;">A</text>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 12 KiB |
@@ -0,0 +1,108 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg width="100%" height="100%" viewBox="0 0 2021 852" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:1.41421;">
|
||||
<g transform="matrix(1,0,0,1,-187,-683)">
|
||||
<g>
|
||||
<g>
|
||||
<g transform="matrix(0.824429,0,0,0.824429,40.8885,111.226)">
|
||||
<rect x="195.263" y="711.481" width="997.627" height="997.627" style="fill:rgb(235,235,235);stroke-width:20.22px;stroke:black;"/>
|
||||
</g>
|
||||
<g>
|
||||
<g transform="matrix(1,0,0,1,324.539,-65.9235)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(248,0,230);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-62.3224,-805.515)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">B</text>
|
||||
</g>
|
||||
</g>
|
||||
<g>
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(82,110,255);"/>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-386.861,-739.592)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">A</text>
|
||||
</g>
|
||||
</g>
|
||||
<g>
|
||||
<g transform="matrix(1,0,0,1,291.652,223.089)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(109,255,87);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-97.6439,-516.503)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">D</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,-17.2537,10.505)">
|
||||
<text x="245.684px" y="752.356px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Environment 1</text>
|
||||
</g>
|
||||
<g>
|
||||
<g transform="matrix(1,0,0,1,-9.40327,285.266)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(255,255,49);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-398.699,-454.326)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">C</text>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g>
|
||||
<g transform="matrix(0.824429,0,0,0.824429,1209.24,111.226)">
|
||||
<rect x="195.263" y="711.481" width="997.627" height="997.627" style="fill:rgb(235,235,235);stroke-width:20.22px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(0.333632,0,0,0.333632,1745.99,939.675)">
|
||||
<g transform="matrix(1,0,0,1,324.539,-65.9235)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(80,254,255);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-62.3224,-805.515)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">G</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,1165.64,10.505)">
|
||||
<text x="245.684px" y="752.356px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Environment 2</text>
|
||||
</g>
|
||||
<g transform="matrix(0.333632,0,0,0.333632,1563.39,529.401)">
|
||||
<g transform="matrix(1,0,0,1,324.539,-65.9235)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(248,0,230);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-62.3224,-805.515)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">B</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(0.333632,0,0,0.333632,1745.51,807.014)">
|
||||
<g transform="matrix(1,0,0,1,324.539,-65.9235)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(255,201,226);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-62.3224,-805.515)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">F</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(0.333632,0,0,0.333632,1711.84,590.465)">
|
||||
<g transform="matrix(1,0,0,1,324.539,-65.9235)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(255,95,111);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-62.3224,-805.515)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">E</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(1.74862,0,0,1.74862,827.639,-680.448)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(82,110,255);"/>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-386.861,-739.592)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">A</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(0.468295,0,0,0.468295,1493.29,758.779)">
|
||||
<g transform="matrix(1,0,0,1,291.652,223.089)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(109,255,87);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-97.6439,-516.503)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">D</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(0.311548,0,0,0.311548,1336.31,890.508)">
|
||||
<g transform="matrix(1,0,0,1,-9.40327,285.266)">
|
||||
<ellipse cx="477.16" cy="995.163" rx="110.023" ry="109.093" style="fill:rgb(255,255,49);"/>
|
||||
</g>
|
||||
<g transform="matrix(1.76539,0,0,1.76539,-398.699,-454.326)">
|
||||
<text x="472.748px" y="995.259px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">C</text>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 7.1 KiB |
@@ -0,0 +1,66 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg width="100%" height="100%" viewBox="0 0 1846 1637" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:1.41421;">
|
||||
<g transform="matrix(1,0,0,1,-105,-316)">
|
||||
<g>
|
||||
<g>
|
||||
<g transform="matrix(3.56657,0,0,3.42572,-1715.29,-1858.59)">
|
||||
<ellipse cx="815.464" cy="910.747" rx="208.192" ry="186.092" style="fill:rgb(235,235,235);stroke-width:4.77px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(2.37512,0,0,2.37512,-1050.26,-4483.8)">
|
||||
<text x="805.445px" y="2617.15px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Environment</text>
|
||||
</g>
|
||||
</g>
|
||||
<g>
|
||||
<g transform="matrix(0.875323,0,0,0.814584,53.5525,-933.789)">
|
||||
<ellipse cx="826.904" cy="2457.22" rx="238.262" ry="246.522" style="fill:rgb(142,255,140);stroke-width:19.71px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(2.01739,0,0,2.01739,-329.967,-4026.53)">
|
||||
<text x="483.571px" y="2537.83px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Site <tspan x="580.861px " y="2537.83px ">A</tspan></text>
|
||||
</g>
|
||||
</g>
|
||||
<g>
|
||||
<g transform="matrix(0.875323,0,0,0.814584,495.154,-585.114)">
|
||||
<ellipse cx="826.904" cy="2457.22" rx="238.262" ry="246.522" style="fill:rgb(255,178,148);stroke-width:19.71px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(2.01739,0,0,2.01739,126.222,-3672.28)">
|
||||
<text x="483.571px" y="2537.83px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Site B</text>
|
||||
</g>
|
||||
</g>
|
||||
<g>
|
||||
<g transform="matrix(0.875323,0,0,0.814584,875.962,-933.789)">
|
||||
<ellipse cx="826.904" cy="2457.22" rx="238.262" ry="246.522" style="fill:rgb(252,255,142);stroke-width:19.71px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(2.01739,0,0,2.01739,486.877,-4026.53)">
|
||||
<text x="483.571px" y="2537.83px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">Site C</text>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(1.90555,0,0,1.90555,-1159.48,-204.501)">
|
||||
<text x="1107.37px" y="318.159px" style="font-family:'STIXGeneral-Regular', 'STIXGeneral';font-size:65.598px;fill:black;">𝛂-div<tspan x="1253.72px " y="318.159px ">e</tspan>rsity</text>
|
||||
</g>
|
||||
<g transform="matrix(1.90555,0,0,1.90555,-2008.56,1318.74)">
|
||||
<text x="1107.37px" y="318.159px" style="font-family:'STIXGeneral-Italic', 'STIXGeneral';font-style:italic;font-size:65.598px;fill:black;">𝛾</text>
|
||||
<text x="1135.45px" y="318.159px" style="font-family:'STIXGeneral-Regular', 'STIXGeneral';font-size:65.598px;fill:black;">-div<tspan x="1239.55px " y="318.159px ">e</tspan>rsity</text>
|
||||
</g>
|
||||
<g transform="matrix(1.90555,0,0,1.90555,-1535.83,762.329)">
|
||||
<text x="1107.37px" y="318.159px" style="font-family:'STIXGeneral-Italic', 'STIXGeneral';font-style:italic;font-size:50px;fill:black;">𝛽</text>
|
||||
<text x="1132.02px" y="318.159px" style="font-family:'STIXGeneral-Regular', 'STIXGeneral';font-size:50px;fill:black;">-div<tspan x="1211.37px " y="318.159px ">e</tspan>rsity</text>
|
||||
</g>
|
||||
<g transform="matrix(-2.57949e-16,1.40421,-7.56783,-1.39019e-15,3559.03,56.614)">
|
||||
<path d="M287.175,308.403L287.175,306.419L860.49,306.419L860.49,303.444L913.72,307.411L860.49,311.379L860.49,308.403L287.175,308.403Z" style="fill:black;stroke-width:0.69px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(-0.612613,0.844268,-6.71099,-4.86959,3409.58,1712.57)">
|
||||
<path d="M287.175,308.403L287.175,306.419L835.211,306.419L835.211,303.444L913.72,307.411L835.211,311.379L835.211,308.403L287.175,308.403Z" style="fill:black;stroke-width:0.63px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(0.251261,-0.311578,5.89101,4.75059,-1333.11,417.689)">
|
||||
<path d="M287.175,308.403L287.175,306.419L726.98,306.419L726.98,303.444L913.72,307.411L726.98,311.379L726.98,308.403L287.175,308.403Z" style="fill:black;stroke-width:0.7px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(0.437815,0.363403,-4.83348,5.8232,2225.37,-773.088)">
|
||||
<path d="M418.542,308.403L418.542,311.379L287.175,307.411L418.542,303.444L418.542,306.419L782.353,306.419L782.353,303.444L913.72,307.411L782.353,311.379L782.353,308.403L418.542,308.403Z" style="fill:black;stroke-width:0.7px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(0.345195,0.841982,-6.44148,2.64087,3196.59,-594.14)">
|
||||
<path d="M287.175,308.403L287.175,306.419L838.159,306.419L838.159,303.444L913.72,307.411L838.159,311.379L838.159,308.403L287.175,308.403Z" style="fill:black;stroke-width:0.76px;stroke:black;"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 5.4 KiB |
@@ -0,0 +1,34 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg width="100%" height="100%" viewBox="0 0 1502 1501" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:1.41421;">
|
||||
<g transform="matrix(1,0,0,1,-380,-775)">
|
||||
<g transform="matrix(1,0,0,1.48478,0,-917.84)">
|
||||
<path d="M775.395,1921.11L775.395,1913.9L1685.12,1913.9L1685.12,1893.32L1756.93,1917.5L1685.12,1941.69L1685.12,1921.11L775.395,1921.11Z" style="fill:rgb(0,1,2);"/>
|
||||
</g>
|
||||
<g transform="matrix(0.605804,-0.795614,1.18131,0.899484,-1951.37,817.912)">
|
||||
<path d="M775.395,1921.11L775.395,1913.9L1685.12,1913.9L1685.12,1893.32L1756.93,1917.5L1685.12,1941.69L1685.12,1921.11L775.395,1921.11Z" style="fill:rgb(0,1,2);"/>
|
||||
</g>
|
||||
<g transform="matrix(3.8068,0,0,3.89337,-3178.36,-6714.08)">
|
||||
<circle cx="1035.39" cy="2222.51" r="260.137" style="fill:none;stroke-width:0.87px;stroke-dasharray:0.87,3.46,0.87,0;stroke:black;"/>
|
||||
</g>
|
||||
<path d="M2051.47,1936.49L526.666,1926.49" style="fill:none;stroke-width:3.33px;stroke-dasharray:3.33,13.33,3.33,0;stroke:black;"/>
|
||||
<g transform="matrix(6.12323e-17,-1,1,6.12323e-17,-1146.44,2711.11)">
|
||||
<path d="M2051.47,1936.49L526.666,1926.49" style="fill:none;stroke-width:3.33px;stroke-dasharray:3.33,13.33,3.33,0;stroke:black;"/>
|
||||
</g>
|
||||
<path d="M1378.06,1143.23L1754.19,1928.24" style="fill:none;stroke-width:8.33px;stroke:rgb(253,36,0);"/>
|
||||
<g transform="matrix(6.12323e-17,-1,1,6.12323e-17,-359.004,3304.88)">
|
||||
<path d="M1378.06,1143.23L1754.19,1928.24" style="fill:none;stroke-width:8.33px;stroke-dasharray:8.33,33.33,8.33,0;stroke:rgb(253,36,0);"/>
|
||||
</g>
|
||||
<g transform="matrix(-3.81475e-16,-2.37218,2.37218,-3.81475e-16,-3006.71,2967.43)">
|
||||
<path d="M437.279,1709.62C472.759,1709.62 506.172,1692.93 527.486,1664.57L437.279,1596.78L437.279,1709.62Z" style="fill:none;stroke-width:3.51px;stroke-dasharray:3.51,14.05,3.51,0;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,-11.9118,184.176)">
|
||||
<text x="1089.21px" y="1669.29px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">cos(</text>
|
||||
<text x="1183.67px" y="1669.29px" style="font-family:'STIXGeneral-Regular', 'STIXGeneral';font-size:50px;fill:black;">𝛼</text>
|
||||
<text x="1209.87px" y="1669.29px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">)=R</text>
|
||||
</g>
|
||||
<g transform="matrix(2.44125,0,0,1.95351,-2681.3,-1267.15)">
|
||||
<text x="1776.48px" y="1492.45px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:rgb(255,76,31);">d</text>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.9 KiB |
@@ -0,0 +1,32 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg width="100%" height="100%" viewBox="0 0 1267 936" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:1.41421;">
|
||||
<g transform="matrix(1,0,0,1,-473,-887)">
|
||||
<g id="metric" transform="matrix(1,0,0,1,85.1006,-84.2667)">
|
||||
<g transform="matrix(1,0,0,1,0.196399,0)">
|
||||
<path d="M520.389,1821.09L1554.35,1821.09" style="fill:none;stroke-width:1px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(6.12323e-17,-1,-1,-6.12323e-17,2858.39,2245.09)">
|
||||
<path d="M1137.81,2034.33L423.607,2337.94L423.239,1303.71L1137.81,2034.33Z" style="fill:none;stroke-width:1px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(2.46916,0,0,2.46916,-1742.45,-175.128)">
|
||||
<text x="1022.83px" y="500.74px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">C</text>
|
||||
</g>
|
||||
<g transform="matrix(2.46916,0,0,2.46916,-2137.03,670.818)">
|
||||
<text x="1022.83px" y="500.74px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">A</text>
|
||||
</g>
|
||||
<g transform="matrix(2.46916,0,0,2.46916,-946.651,670.818)">
|
||||
<text x="1022.83px" y="500.74px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">B</text>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,19.4596,34.2956)">
|
||||
<circle cx="505.904" cy="1785.24" r="15.508" style="fill:rgb(255,120,60);stroke-width:3.33px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,1044.28,33.9027)">
|
||||
<circle cx="505.904" cy="1785.24" r="15.508" style="fill:rgb(255,120,60);stroke-width:3.33px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,319.278,-679.347)">
|
||||
<circle cx="505.904" cy="1785.24" r="15.508" style="fill:rgb(255,120,60);stroke-width:3.33px;stroke:black;"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.2 KiB |
|
After Width: | Height: | Size: 408 KiB |
@@ -0,0 +1,44 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg width="100%" height="100%" viewBox="0 0 1267 1445" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:1.41421;">
|
||||
<g transform="matrix(1,0,0,1,-388,-463)">
|
||||
<g id="Umtrametric">
|
||||
<g transform="matrix(1,0,0,1,0.196399,0)">
|
||||
<path d="M520.389,1821.09L1554.35,1821.09" style="fill:none;stroke-width:1px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(6.12323e-17,-1,-1,-6.12323e-17,2858.39,2245.09)">
|
||||
<path d="M1554.35,1821.09L423.607,2337.94L423.239,1303.71L1554.31,1821" style="fill:none;stroke-width:1px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(2.46916,0,0,2.46916,-1532.55,-683.049)">
|
||||
<text x="1022.83px" y="500.74px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">C</text>
|
||||
</g>
|
||||
<g transform="matrix(2.46916,0,0,2.46916,-2137.03,670.818)">
|
||||
<text x="1022.83px" y="500.74px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">A</text>
|
||||
</g>
|
||||
<g transform="matrix(2.46916,0,0,2.46916,-946.651,670.818)">
|
||||
<text x="1022.83px" y="500.74px" style="font-family:'ArialMT', 'Arial', sans-serif;font-size:50px;fill:black;">B</text>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,19.4596,34.2956)">
|
||||
<circle cx="505.904" cy="1785.24" r="15.508" style="fill:rgb(255,120,60);stroke-width:3.33px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,1044.28,33.9027)">
|
||||
<circle cx="505.904" cy="1785.24" r="15.508" style="fill:rgb(255,120,60);stroke-width:3.33px;stroke:black;"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,529.835,-1093.64)">
|
||||
<circle cx="505.904" cy="1785.24" r="15.508" style="fill:rgb(255,120,60);stroke-width:3.33px;stroke:black;"/>
|
||||
</g>
|
||||
<g>
|
||||
<path d="M740.104,1216.22L832.267,1257.12" style="fill:none;stroke-width:3.33px;stroke:black;"/>
|
||||
<g transform="matrix(1,0,0,1,7,-17)">
|
||||
<path d="M740.104,1216.22L832.267,1257.12" style="fill:none;stroke-width:3.33px;stroke:black;"/>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(-1,0,0,1,2071.79,-0.155385)">
|
||||
<path d="M740.104,1216.22L832.267,1257.12" style="fill:none;stroke-width:3.33px;stroke:black;"/>
|
||||
<g transform="matrix(1,0,0,1,7,-17)">
|
||||
<path d="M740.104,1216.22L832.267,1257.12" style="fill:none;stroke-width:3.33px;stroke:black;"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.9 KiB |
@@ -0,0 +1,60 @@
|
||||
%% This BibTeX bibliography file was created using BibDesk.
|
||||
%% http://bibdesk.sourceforge.net/
|
||||
|
||||
|
||||
%% Created for Eric Coissac at 2018-10-18 14:52:51 +0200
|
||||
|
||||
|
||||
%% Saved with string encoding Unicode (UTF-8)
|
||||
|
||||
|
||||
|
||||
@article{Tsallis:94:00,
|
||||
Author = {Tsallis, Constantino},
|
||||
Date-Added = {2018-10-18 14:52:41 +0200},
|
||||
Date-Modified = {2018-10-18 14:52:49 +0200},
|
||||
Journal = {Quim. Nova},
|
||||
Number = 6,
|
||||
Pages = {468--471},
|
||||
Title = {What are the numbers that experiments provide},
|
||||
Volume = 17,
|
||||
Year = 1994}
|
||||
|
||||
|
||||
@ARTICLE{Whittaker:10:00,
|
||||
title = "Meta-analyses and mega-mistakes: calling time on meta-analysis
|
||||
of the species richness-productivity relationship",
|
||||
author = "Whittaker, Robert J",
|
||||
abstract = "The form of the species richness-productivity relationship
|
||||
(SRPR) is both theoretically important and contentious. In an
|
||||
effort to distill general patterns, ecologists have undertaken
|
||||
meta-analyses, within which each SRPR data set is first
|
||||
classified into one of five alternative forms: positive, humped
|
||||
(unimodal), negative, U-shaped (unimodal), and no relationship.
|
||||
Herein, I first provide a critique of this approach, based on 68
|
||||
plant data sets/ studies used in three meta-analyses published
|
||||
in Ecology. The meta-analyses are shown to have resulted in
|
||||
highly divergent outcomes, inconsistent and often highly
|
||||
inappropriate classification of data sets, and the introduction
|
||||
and multiplication of errors from one meta-analysis to the next.
|
||||
I therefore call on the ecological community at large to adopt a
|
||||
far more rigorous and critical attitude to the use of
|
||||
meta-analysis. Second, I develop the argument that the
|
||||
literature on the SRPR continues to be bedeviled by a common
|
||||
failing to appreciate the fundamental importance of the scale of
|
||||
analysis, beginning with the confusion evident between concepts
|
||||
of grain, focus, and extent. I postulate that variation in the
|
||||
form of the SRPR at fine scales of analysis owes much to
|
||||
artifacts of the sampling regime adopted. An improved
|
||||
understanding may emerge from combining sampling theory with an
|
||||
understanding of the factors controlling the form of species
|
||||
abundance distributions and species accumulation curves.",
|
||||
journal = "Ecology",
|
||||
publisher = "Eco Soc America",
|
||||
volume = 91,
|
||||
number = 9,
|
||||
pages = "2522--2533",
|
||||
month = sep,
|
||||
year = 2010
|
||||
}
|
||||
|
||||