Last updated: 2020-04-28

Checks: 2 0

Knit directory: BgeeCall_practical/

This reproducible R Markdown analysis was created with workflowr (version 1.6.1). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.


Great! Since the R Markdown file has been committed to the Git repository, you know the exact version of the code that produced these results.

Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.

The results in this page were generated with repository version ffd74c0. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.

Note that you need to be careful to ensure that all relevant files for the analysis have been committed to Git prior to generating the results (you can use wflow_publish or wflow_git_commit). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:


Ignored files:
    Ignored:    .Rhistory
    Ignored:    .Rproj.user/

Untracked files:
    Untracked:  PCA_dim_1vs2.png
    Untracked:  PCA_prop_explained_variance.png
    Untracked:  analyis.R
    Untracked:  dif_expressed_genes.tsv
    Untracked:  inputFile.tsv
    Untracked:  input_files/
    Untracked:  merge.R
    Untracked:  output_files/
    Untracked:  release.tsv

Unstaged changes:
    Modified:   analysis/_site.yml

Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.


These are the previous versions of the repository in which changes were made to the R Markdown (analysis/exercises.Rmd) and HTML (docs/exercises.html) files. If you’ve configured a remote Git repository (see ?wflow_git_remote), click on the hyperlinks in the table below to view the files as they were in that past version.

File Version Author Date Message
Rmd ffd74c0 Julien 2020-04-28 wflow_publish(files = c(“analysis/analysis.Rmd”, “analysis/classes_description.Rmd”,
html a753e15 Julien 2020-04-28 Build site.
Rmd 3bcbb2e Julien 2020-04-28 wflow_publish(files = c(“analysis/analysis.Rmd”, “analysis/classes_description.Rmd”,

Introduction

4 RNA-Seq libraries (SRX109271, SRX109272, SRX109273, SRX109274) of Drosophila melanogaster just arrived in your RStudio cloud project.
All data you need are stored in the input_files directory at the root of your project.
You and your virtual colleague have one hour to analyse these data and escape the Zoom room.

Exercise 1 : One library

Generate present/absent expression calls for the RNA-Seq library SRX109273.
Explanations of BgeeCall classes and their most important slots are available in the page BgeeCall classes
Examples of R commands are available in the page One library

Important information :
D. melanogaster NCBI ID : 7227
read length for this library is 76bp
GTF gene annotations file and fasta transcriptome file are in the directory input_files/ensembl
fastq files are in the directory input_files/fastq/SRX109273/
Even if the generation of kallisto index takes time, you can still manage to escape the Zoom room on time.

  • What is the TPM threshold of this library ?
  • What is the proportion of protein coding genes present ?
  • Have a look at the density plot of abundance

Exercise 2 : List of libraries

Generate present/absent expression calls for the libraries SRX109272 using a file as input R commands and explanation of columns of the file are available in the page List of libraries Explanation of BgeeCall classes and their most important slots are available in the page BgeeCall classes

Important information :
A template of the tsv (Tabular Separated Values) file is available at input_files/inputFile.tsv.
This file already contains information to run BgeeCall for library SRX109273 (Exercise 1). You can keep these information and run BgeeCall for 2 libraries or remove them and run BgeeCall only for library SRX109272.
fastq files of library SRX109272 are in the directory input_files/fastq/SRX109272/
Do not forget to provide the same working_path than in Exercise 1 in order to use previously generated kallisto index

Information about the cutoff for this library are available at YOUR_OUTPUT_DIR/gene_cutoff_info_file.tsv

  • What is the TPM threshold of this library ?
  • What is the proportion of protein coding genes present ?
  • Have a look at the plot of abundance distribution
  • Have a look at the calls

Exercise 3 : Principle component analysis (PCA)

Fortunatly your colleague worked well and run BgeeCall on the 2 remaining libraries. The output of BgeeCall for the 4 libraries are available at output_files/libraries/. Your colleague even merged TPM values of the 4 libraries in one file where rows correspond to genes and columns correspond to libraries.
More importantly, she only kept in this file genes considered as present in the 4 libraries.
Everything is ready for downstream analysis. She is now counting on you to do a PCA on these data

Important information :
The file generated by your colleague is available at input_files/downstream_analysis/present_TPMs.tsv The code to run the PCA is described in the page Processing data

  • Check the 2 plots generated by this code, Which RNA-Seq libraries cluster together.
  • Annotations of these libraries are available at input_files/downstream_analysis/library_annotations.tsv. How do these annotations corroborate the PCA?

Exercise 4 : Differential expression

Once more your colleague was extremely productive. She merged raw counts of the 4 libraries in one file where rows correspond to genes and columns correspond to libraries.
More importantly, she only kept in this file genes considered as present in the 4 libraries.
She is now counting on you to do a differential expression analysis on these data.

Important information :
The file generated by your collaborator is available at input_files/downstream_analysis/present_counts.tsv The code to run the Differential expression is described in the page Processing data

  • Which are the top 10 most differentially expressed genes?
  • How many genes are considered differentially expressed if you use a threshold of p-value=0.01 and aboslute value of logFC=2
  • Run again the differential expression analysis using the file input_files/downstream_analysis/present_counts.tsv. This file contains all genes (even those with absence of expression). What is the impact of removing genes with absence of expression? (The aim of this question is to see impact of not removing genes with absence of expression. DE analysis should be done on expressed genes only)

Congratulations!!!!
You managed to escape the Zoom room on time. Your virtual colleague is virtually extremely proud of you.

Optional Exercise

If you are never full of data analysis you are maybe frustrated not to be able to interprete the differential expression results in terms of biological processes, molecular functions or cellular component. In this case you can run a GO analysis.
The code is described in the page Processing data