Slide 1

Slide 1 text

11 Reproducible Research and Bioinformatics Leonardo Collado-Torres @fellgernon http://lcolladotor.github.io/

Slide 2

Slide 2 text

Reproducible research 2 What is reproducible research? • Have you heard about it? • How would you definite it? • Is it the same as replicability? • Is it important?

Slide 3

Slide 3 text

Reproducible research 3 Research • Science moves forward then discoveries are replicated and reproduced Implementing Reproducible Research by Stodden, Leish, Peng

Slide 4

Slide 4 text

https://www.nature.com/news/1-500-scientists-lift-the-lid-on-reproducibility-1.19970

Slide 5

Slide 5 text

https://www.nature.com/news/1- 500-scientists-lift-the-lid-on- reproducibility-1.19970

Slide 6

Slide 6 text

Open Science Collaboration, Science, 2015 35/97 (36%) replications P < 0.05 in same direction

Slide 7

Slide 7 text

https://simplystatistics.org/2017/03/02/rr-glossy/

Slide 8

Slide 8 text

https://github.com/jtleek/replication_paper/blob/gh-pages/in_the_media.md

Slide 9

Slide 9 text

Patil, Peng & Leek, Perspectives on Psychological Science, 2016

Slide 10

Slide 10 text

Researchers need a new definition for replication that acknowledges variation in both the original study and in the replication study. Specifically, a study replicates if the data collected from the replication are drawn from the same distribution as the data from the original experiment. Multiple independent replications of the same study will be needed to definitively evaluate replication. Patil, Peng & Leek, Perspectives on Psychological Science, 2016 Reproducible research Key conclusions:

Slide 11

Slide 11 text

Reproducible research 11 Replication • Replication, the practice of independently implementing scientific experiments to validate specific findings, is the cornerstone of discovering scientific truth. Implementing Reproducible Research by Stodden, Leish, Peng

Slide 12

Slide 12 text

Kim et al, biorXiv, 2017

Slide 13

Slide 13 text

Kim et al, biorXiv, 2017

Slide 14

Slide 14 text

Reproducible research 14 Reproducibility: from back in 2006 • However, because of the time, expense, and opportunism of many current epidemiologic studies, it is often impossible to fully replicate their findings. An attainable minimum standard is "reproducibility," which calls for data sets and software to be made available for verifying published findings and conducting alternative analyses. Peng et al, Reproducible epidemiologic research, Am J Epidemiol., 2006

Slide 15

Slide 15 text

Reproducible research 15 Reproducibility • Reproducibility can be thought of as a different standard of validity from replication because it forgoes independent data collection and uses the methods and data collected by the original investigator. Implementing Reproducible Research by Stodden, Leish, Peng

Slide 16

Slide 16 text

Reproducible research 16 A bit more practical • The sharing of analytic data and computer codes uses to map those data into computational results is central to any comprehensive definition of reproducibility. Implementing Reproducible Research by Stodden, Leish, Peng

Slide 17

Slide 17 text

Reproducible research 17 Why is it important? • Except for the simplest of analyses, the computer code used to analyze a dataset is the only record that permits others to fully understand what a researcher has done. Implementing Reproducible Research by Stodden, Leish, Peng

Slide 18

Slide 18 text

Reproducible research 18 Drawing the line

Slide 19

Slide 19 text

Reproducible research 19 Together • Reproducibility is the ability to take the code and data from a previous publication, rerun the code and get the same results. Replicability is the ability to rerun an experiment and get “consistent” results with the original study using new data. Results that are not reproducible are hard to verify and results that do not replicate in new studies are harder to trust. https://simplystatistics.org/2017/03/02/rr-glossy/

Slide 20

Slide 20 text

Reproducible research 20 Visually Patil, Peng & Leek, biorXiv, 2016 http://biorxiv.org/content/early/2016/07/29/066803

Slide 21

Slide 21 text

http://science.sciencemag.org/content/354/6317/1240

Slide 22

Slide 22 text

http://rpubs.com/lcollado/4080

Slide 23

Slide 23 text

Reproducible research 23 Reproducible documents • Have you ever had your code in one file, your description of the results in another file? • Ever made copy-paste mistakes? • What if you were asked to change some models or revise the document? • Was it easy to maintain?

Slide 24

Slide 24 text

Reproducible research 24 Reproducible documents • What would be a reproducible document for you?

Slide 25

Slide 25 text

Reproducible research 25 Reproducible documents in R • R Markdown is the easiest • It's based on Markdown: simple human readable syntax • You maintain a single file! It has the • code, • figures, • description of results. • It then creates a file in the format you want to share with others.

Slide 26

Slide 26 text

Reproducible research 26 R Markdown http://rmarkdown.rstudio.com/

Slide 27

Slide 27 text

Reproducible research 27 R Markdown http://rmarkdown.rstudio.com/

Slide 28

Slide 28 text

https://github.com/leekgroup/polyester_code/blob/master/polyester_manuscript.Rmd Complex example

Slide 29

Slide 29 text

http://htmlpreview.github.io/?https://github.com/alyssafrazee/polyester_code/blob/master/polyester_manuscript.html

Slide 30

Slide 30 text

Reproducible research 30 Reproducible research can still be wrong! • Unfortunately, the mere reproducibility of computational results is insufficient to address the replication crisis because even a reproducible analysis can suffer from many problems—confounding from omitted variables, poor study design, missing data—that threaten the validity and useful interpretation of the results. Although improving the reproducibility of research may increase the rate at which flawed analyses are uncovered […] it does not change the fact that problematic research is conducted in the first place. Leek and Peng, PNAS, 2015

Slide 31

Slide 31 text

https://www.nature.com/ news/1-500-scientists- lift-the-lid-on- reproducibility-1.19970

Slide 32

Slide 32 text

Bioinformatics 32 Dictionary definition https://www.merriam-webster.com/dictionary/bioinformatics

Slide 33

Slide 33 text

Bioinformatics http://hyperphysics.phy-astr.gsu.edu/hbase/Organic/dogma.html

Slide 34

Slide 34 text

Bioinformatics http://www.batcallid.com/canBCIDfeatures.html

Slide 35

Slide 35 text

Bioinformatics https://www.evogeneao.com/learn/tree-of-life

Slide 36

Slide 36 text

● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● 0 3000 6000 9000 1970 1980 1990 2000 2010 Year Yearly PDB sequences over time Bioinformatics http://www.rcsb.org/pdb/statistics/contentGrowthChart.do?content=total&seqid=100

Slide 37

Slide 37 text

● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● 0e+00 5e+04 1e+05 1970 1980 1990 2000 2010 Year Total PDB sequences over time Bioinformatics http://www.rcsb.org/pdb/statistics/contentGrowthChart.do?content=total&seqid=100

Slide 38

Slide 38 text

Bioinformatics https://www.ncbi.nlm.nih.gov/genbank/statistics/

Slide 39

Slide 39 text

Bioinformatics 39 Luscombe et al., Methods Inf Med., 2011

Slide 40

Slide 40 text

Bioinformatics http://hyperphysics.phy-astr.gsu.edu/hbase/Organic/dogma.html

Slide 41

Slide 41 text

Genome Transcripts

Slide 42

Slide 42 text

Bioinformatics http://www.sequence-alignment.com/ https://commons.wikimedia.org/wiki/File:Sequence_alignment_dendrotoxins.jpg

Slide 43

Slide 43 text

Bioinformatics https://blast.ncbi.nlm.nih.gov/Blast.cgi

Slide 44

Slide 44 text

Bioinformatics Wilks et al., biorXiv, 2017

Slide 45

Slide 45 text

Bioinformatics

Slide 46

Slide 46 text

Bioinformatics Wilks et al., biorXiv, 2017

Slide 47

Slide 47 text

Bioinformatics

Slide 48

Slide 48 text

Bioinformatics Wilks et al., biorXiv, 2017

Slide 49

Slide 49 text

Bioinformatics 49 Aims • Organize data, allow new entries, data curation • Develop tools and resources that aid in the analysis of data • Use these tools to analyze the data and interpret the results in a biologically meaningful manner Luscombe et al., Methods Inf Med., 2011

Slide 50

Slide 50 text

Bioinformatics 50 Welch et al., PLoS Comp Bio, 2014 Recommended curriculum

Slide 51

Slide 51 text

http://www.nature.com/news/don-t-let-useful-data-go-to-waste-1.21555

Slide 52

Slide 52 text

AUCAGUCGAUCACCGAU transcription RNA translation protein ACTGACCTAGATCAGTCGATCGATCGTATACGATTACAAAATCATCGGCAT DNA M M M slide adapted from Alyssa Frazee

Slide 53

Slide 53 text

AUCAGUCGAUCACCGAU transcription RNA translation protein ACTGACCTAGATCAGTCGATCGATCGTATACGATTACAAAATCATCGGCAT DNA M M M Bisulfite RNA ChIP Genome slide adapted from Alyssa Frazee

Slide 54

Slide 54 text

AUCAGUCGAUCACCGAU transcription RNA translation protein ACTGACCTAGATCAGTCGATCGATCGTATACGATTACAAAATCATCGGCAT DNA M M M RNA slide adapted from Alyssa Frazee

Slide 55

Slide 55 text

Genome Transcripts Reads

Slide 56

Slide 56 text

@22:16362385-16362561W:ENST00000440999:2:177:-40:244:S/2 CCAGCCCACCTGAGGCTTCTTTTTCCTTCCCAAGCCACATCACCATCCTGGTGGAACTCTCCTGTGAGGACAGCCA + GGFFGBGIIIIIIIIIIIIIIEGEHGHHIIIIIIIIHFHBB2/:=??EGGGEGFHHIHHEDBD?@@DDHHD @22:16362385-16362561W:ENST00000440999:3:177:-56:294:S/2 GCGTGAGCCACAGGGCCCAGCCCACCTGAGGCTTCTTTTTCCTTCCCAAGCCACATCACCATCCTGGTGGAACTCT + @=ABBBBIIIIIIIIHHGGGGIIDBDIIIIIIGIIIIHIIIIHFDD@BBDBGGFIDEE8DCC/29>BGFCGHHHGF @22:16362385-16362561W:ENST00000440999:4:177:137:254:S/1 TCACCATCCTGGTGGAACTCTCCTGTGAGGACAGCCAAGGCCTGAACTACCTGCaGTGGGGAGCACCTCAGGGTTT + DDGBBCGGGIGGGBDDDHIIGGDGD77=BDIIIIIIIIFHHHHIIIHEFFHGGDD8A>DEGHHIFDDHH8@BEDDI @22:16362385-16362561W:ENST00000440999:5:177:68:251:S/2 AGGGTTTGCCCAGGCAACCAGCCAGCCCTGGTCCAAGGCATCCTGGAGCGAGTTGTGGATGGCAAAAAGACNCGCC + HIGHIHFHEGE4111:.;8@?@HDIIIIIIIEGGIHHHIIGA?=:FIIIDD8.02506A8=AC############# @22:16362385-16362561W:ENST00000440999:6:177:348:453:S/1 AAGGCCTGAACTACCTGCGGTGGGGAGCACCTCAGGGTTTGCCCAGGCAACCAGCCAGCCCTGGTCCAAGGCATCC + B9?@8=42:E@GDEDIIIIIGGHIIIFBEEAGIIDIIDHHGGHIIEGEIIIIIHIHFHFFEEFGGGGGB88>:DGH @22:51205934-51222090C:ENST00000464740:132:612:223:359:S/2 GGAAGTATGATGCTGATGACAACGTGAAGATCATCTGCCTGGGAGACAGCGCAGTGGGCAAATCCAAACTCATGGA + IIEHHHHHIIIIIIIHGGDGHHEDDG8=;?==19;<<>D@@GGGIIHIIHGGDDHGBA=ABEG@@DFCCAA<:=>8 @22:51205934-51222090C:ENST00000464740:125:612:-1:185:S/1 TGGAGTGCGCTGCGGCGCGAGCTGGGCCGGCGGGCGTGGTTCGAGAGCGCGCAGAGTCCAGACTGGCGGCAGGGCC + HHIIIHIDGG@;=@GIIIIIDDGBBBEDB@8>5554,/':9B@@C?==@1:2@?=GG=;

Slide 57

Slide 57 text

GTEx TCGA slide adapted from Shannon Ellis

Slide 58

Slide 58 text

SRA

Slide 59

Slide 59 text

Slide adapted from Ben Langmead

Slide 60

Slide 60 text

Genome

Slide 61

Slide 61 text

http://rail.bio/ Slide adapted from Ben Langmead

Slide 62

Slide 62 text

http://blogs.citrix.com/2012/10/17/announcing-general-availability-of-sharefile-with-storagezones/

Slide 63

Slide 63 text

Obstacle: our research moves (spot) markets Spike in market price due to preprocessing job flows slide adapted from Jeff Leek

Slide 64

Slide 64 text

Obstacle: our research moves (spot) markets Weekday market volatility Weekend EC2 inactivity slide adapted from Jeff Leek

Slide 65

Slide 65 text

https://jhubiostatistics.shinyapps.io/recount/

Slide 66

Slide 66 text

jx 1 jx 2 jx 3 jx 4 jx 5 jx 6 Coverage Reads Gene Isoform 1 Isoform 2 Potential isoform 3 exon 1 exon 2 exon 3 exon 4 Expressed region 1: potential exon 5

Slide 67

Slide 67 text

> library('recount') > download_study( 'ERP001942', type='rse-gene') > load(file.path('ERP001942 ', 'rse_gene.Rdata')) > rse <- scale_counts(rse_gene) https://github.com/leekgroup/recount-analyses/

Slide 68

Slide 68 text

expression data for ~70,000 human samples GTEx N=9,962 TCGA N=11,284 SRA N=49,848 samples expression estimates gene exon junctions ERs slide adapted from Shannon Ellis

Slide 69

Slide 69 text

expression data for ~70,000 human samples Answer meaningful questions about human biology and expression GTEx N=9,962 TCGA N=11,284 SRA N=49,848 samples expression estimates gene exon junctions ERs slide adapted from Shannon Ellis

Slide 70

Slide 70 text

expression data for ~70,000 human samples samples phenotypes ? GTEx N=9,962 TCGA N=11,284 SRA N=49,848 samples expression estimates gene exon junctions ERs Answer meaningful questions about human biology and expression slide adapted from Shannon Ellis

Slide 71

Slide 71 text

Category Frequency F 95 female 2036 Female 51 M 77 male 1240 Male 141 Total 3640 Even when information is provided, it’s not always clear… sra_meta$Se x “1 Male, 2 Female”, “2 Male, 1 Female”, “3 Female”, “DK”, “male and female” “Male (note: ….)”, “missing”, “mixed”, “mixture”, “N/A”, “Not available”, “not applicable”, “not collected”, “not determined”, “pooled male and female”, “U”, “unknown”, “Unknown” slide adapted from Shannon Ellis

Slide 72

Slide 72 text

Goal : to accurately predict critical phenotype information for all samples in recount gene, exon, exon-exon junction and expressed region RNA-Seq data SRA Sequence Read Archive N=49,848 GTEx Genotype Tissue Expression Project N=9,662 divide samples build and optimize phenotype predictor training set predict phenotypes across SRA samples test accuracy of predictor predict phenotypes across samples in TCGA test set TCGA The Cancer Genome Atlas N=11,284 slide adapted from Shannon Ellis

Slide 73

Slide 73 text

Sex prediction is accurate across data sets Number of Regions 20 20 20 20 Number of Samples (N) 4,769 4,769 11,245 3,640 99.8% 99.6% 99.4% 88.5% slide adapted from Shannon Ellis

Slide 74

Slide 74 text

Number of Regions 589 589 589 589 589 Number of Samples (N) 4,769 4,769 613 6,579 8,951 97.3% 96.5% 91.0% 70.2% Prediction is more accurate in healthy tissue 50.6% slide adapted from Shannon Ellis

Slide 75

Slide 75 text

expression data for ~70,000 human samples samples phenotypes ? GTEx N=9,962 TCGA N=11,284 SRA N=49,848 samples expression estimates gene exon junctions ERs Answer meaningful questions about human biology and expression sex tissue M Blood F Heart F Liver slide adapted from Shannon Ellis

Slide 76

Slide 76 text

bioconductor.org/packages/derfinder bioconductor.org/packages/recount > biocLite(“derfinder”) > biocLite(“recount”) http://rail.bio $ ./install-rail-rna-V

Slide 77

Slide 77 text

Collaborators The Leek Group Jeff Leek Shannon Ellis Hopkins Ben Langmead Chris Wilks Kai Kammers Kasper Hansen Margaret Taub OHSU Abhinav Nellore LIBD Andrew Jaffe Emily Burke Stephen Semick Carrie Wright Amanda Price Nina Rajpurohit Funding NIH R01 GM105705 NIH 1R21MH109956 CONACyT 351535 AWS in Education Seven Bridges IDIES SciServer

Slide 78

Slide 78 text

Bioinformatics 78 Staying Current in Bioinformatics & Genomics • “focused on applied methodology and study design rather than any particular phenotype, model system, disease, or specific method” • “a software implementation that’s well documented, actively supported, and performs well in fair benchmarks” http://www.gettinggeneticsdone.com/

Slide 79

Slide 79 text

Bioinformatics 79 Staying Current in Bioinformatics & Genomics • Twitter • Blogs • Some websites • Pre-prints • Journal articles http://www.gettinggeneticsdone.com/

Slide 80

Slide 80 text

11 Reproducible Research and Bioinformatics Leonardo Collado-Torres @fellgernon http://lcolladotor.github.io/