Skip to content
Snippets Groups Projects
Commit d18af357 authored by Arnaud Duvermy's avatar Arnaud Duvermy
Browse files

update tuto

parent 5d906404
No related branches found
No related tags found
No related merge requests found
......@@ -9,21 +9,15 @@ $$
Phenotype = Genotype + Environment + Genotype.Environment
$$
From this expression, $\beta_{G}$, $\beta_{E}$, $\beta_{G*E}$ can be seen as coefficients which allow quantifying the participation of each factors (Genotype, Environment and interaction Genotype/Environment).
Then,
In mathematical term, it leads to a linear expression such:
$$
P = \beta_{G}*G + \beta_{E}*E + \beta_{G*E}*G.E + \beta_{0}
$$
In order to estimate these coefficients, a Generalized Linear Model (GLM) can be used.
# B. HTRSIM getting started
```{r echo=FALSE, out.width='100%'}
knitr::include_graphics('../img/schema_loop.jpg')
```
This is a tutorial for *htrsim* utilization
<u>a. Required</u>
```{r required, message=FALSE, echo = T, results = "hide"}
library(data.table)
......@@ -40,6 +34,52 @@ setwd("/home/rstudio/mydatalocal/counts_simulation/src/")
```
<u>b. Workflow</u>
```{r echo=FALSE, out.width='50%'}
knitr::include_graphics('../img/schema_loop.jpg')
```
<u>c. RNA-seq pipeline</u>
You can used your favorite pipeline to obtain table counts from real data.
If you don't have any idea of how to obtain such table counts rdv [at](https://gitbio.ens-lyon.fr/aduvermy/rna-seq_public_library_investigations)
<u> d. BioProject PRJNA675209b as input</u>
To easily test *HTRSIM* we produced an usual table counts from BioProject PRJNA675209b.
Take the time to clean up your table counts.
```{r}
tabl_cnts <- read.table("/home/rstudio/mydatalocal/rna-seq_public_library_investigations/results/2022-02-09/salmon.merged.gene_counts.tsv", header = TRUE)
rownames(tabl_cnts) <- tabl_cnts$gene_id
tabl_cnts <- tabl_cnts %>% select(-gene_id)##suppr colonne GeneID
tabl_cnts <- tabl_cnts %>% select(-gene_name) ##suppr colonne GeneName
tabl_cnts
```
<u> e. Launch HTRSIM</u>
```{r message=FALSE, warning=FALSE}
## import design of bioProject
bioDesign <- read_csv2(file = "/home/rstudio/mydatalocal/rna-seq_public_library_investigations/data/design_deseq__PRJNA675209.csv")
#bioDesign
source(file = "htrsim/main.R")
tabl_cnts %>% dim()
bioDesign %>% dim()
simul_cnts = htrsim(tabl_cnts, bioDesign = bioDesign, 2)
```
# C. Advance user
This is a tutorial for *htrsim* utilization
To perform counts per genes *htrsim* needs some inputs.</br>
Following parameters are required:</br>
- number of samples</br>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment