A Bayesian framework for personalized design in alternative splicing RNA-seq studies

advertisement
A Bayesian framework for
personalized design in alternative
splicing RNA-seq studies
Camille Stephan-Otto Attolini
Biostatistics and bioinformatics Unit
IRB Barcelona
Workshop on experimental Design and Big Data
May 8th 2015
The University of Warwick
Friday 8 May 15
Introduction
Friday 8 May 15
RNAseq: Big Data, Big Questions
RNAseq is a technique to measure the abundance
(expression) of mRNA in a cell.
The main application is to find differences in expression
between samples in distinct biological conditions
Friday 8 May 15
RNAseq: Big Data, Big Questions
Q: What is the “Big” in the data?
A: Several million reads are generated from a single
sample. These reads correspond to about 20,000 genes in
the human genome and, according to the most
conservative annotations, to more than 40,000 (mostly
overlapping) transcripts
Friday 8 May 15
The question
Find the optimal experimental design to better estimate
transcript level expression and/or to find those transcripts
differentially expressed between conditions while keeping the
number of reads and samples (cost and time) as low as
possible
Friday 8 May 15
Alternative splicing
IN A NUTSHELL
Friday 8 May 15
Alternative splicing
IN A NUTSHELL
Friday 8 May 15
Alternative splicing
IN A NUTSHELL
Friday 8 May 15
Alternative splicing
IN A NUTSHELL
Relative
expression
Friday 8 May 15
35%
65%
RNA sequencing
ALSO IN A NUTSHELL
Friday 8 May 15
RNA sequencing
In a beautiful world
Friday 8 May 15
RNA sequencing
In the real world
Friday 8 May 15
RNAseq
Real data
Friday 8 May 15
Statistical framework
Friday 8 May 15
Statistical framework
The data
- Impossible to model full data (10^7 ~ 10^8 seqs. per
experiment)
- Experimental biases such as uneven distributions of
fragments along transcripts
- Fragment length distributions not always as reported by
lab
Friday 8 May 15
Statistical framework
Exon paths
Friday 8 May 15
Statistical framework
Exon paths
Friday 8 May 15
Path
Fragment Count
1–2
10
Statistical framework
Exon paths
Friday 8 May 15
Path
Fragment Count
1–2
10
1 – 1.2
56
Statistical framework
Exon paths
Friday 8 May 15
Path
Fragment Count
1–2
10
1 – 1.2
56
2–4
120
Statistical framework
Exon paths
Friday 8 May 15
Path
Fragment Count
1–2
10
1 – 1.2
56
2–4
120
1.2 – 2.3.4
8
Statistical framework
Exon paths
Path
1–2
1 – 1.2
2–4
1.2 – 2.3.4
…
Friday 8 May 15
Fragment Count
10
56
120
8
…
Statistical framework
Fragment start and length distributions
Friday 8 May 15
Bringing all together
The model
Relative
expression
35%
65%
1
Friday 8 May 15
Path
Fragment Count
1–2
10
1 – 1.2
56
2–4
120
1.2 – 2.3.4
8
2
3
4
Bringing all together
The model
Relative
expression
35%
65%
π
Friday 8 May 15
1
Y
Path
Fragment Count
1–2
10
1 – 1.2
56
2–4
120
1.2 – 2.3.4
8
2
3
4
Statistical framework
Bayes rule rules!
P(π|Y) α P(Y|π)P(π)
Friday 8 May 15
Statistical framework
Bayes rule rules!
P(π|Y) α P(Y|π)P(π)
Posterior
probability
Friday 8 May 15
Statistical framework
Bayes rule rules!
P(π|Y) α P(Y|π)P(π)
Likelihood
Friday 8 May 15
Statistical framework
Bayes rule rules!
P(π|Y) α P(Y|π)P(π)
Prior
P(π) = Dir(q) with q = 2 or 3
Friday 8 May 15
The Model
Path counts arise from a mixture (one component
from each variant):
David Rossell et al. Annals of Applied Statistics, 2012
Friday 8 May 15
Statistical framework
Prior
-- q = 2
-- q = 3
Friday 8 May 15
Statistical framework
Model fitting
- EM algorithm to maximize posterior probability
- Find point estimates of relative expressions,
asymptotic credibility intervals and exact posterior
samples
- The algorithm converges to a single maximum
Friday 8 May 15
Reads simulation
Following the same model, we can simulate
reads from a given set of expressions,
reproducing the same technical biases observed
in the data
Friday 8 May 15
Sample size calculation
Friday 8 May 15
Question1: Coverage in a single
sample
What is the number of reads that need to be sequenced in
order to control the estimation error below a certain
threshold?
Friday 8 May 15
Simulation setup
1. Compute relative expressions and distributions for
pilot data (human and mouse)
2. For a range of total bp sequenced simulate under 5
parameter scenarios:
Mean of fragment’s
length
Friday 8 May 15
Read length
200
76
200
101
300
76
300
101
1500
1000
Simulation setup
3. Compute relative expression from simulated data
4. Compute mean absolute error between original
expressions and computed expressions
Friday 8 May 15
Results: One sample problem
0.08
Simulation setting
1000 1500 human
101 200 human
101 300 human
MAE
76 200 human
0.06
76 300 human
1000 1500 mouse
101 200 mouse
101 300 mouse
76 200 mouse
76 300 mouse
0.04
0.02
2e+09
3428571000
4857143000
6285714000
7714286000
Total base pairs sequenced
Friday 8 May 15
9142857000
10571429000
1.2e+10
Results: One sample problem
K562 cell line (Encode)
1000 Genomes
0.05
0.04
Cummulative MAE
0.03
r=101 f=200
r=101 f=300
r=76 f=200
r=76 f=300
0.02
0.01
0.00
Distribution
0.10
0.05
0.00
−5
0
5
10
RPKM
Friday 8 May 15
−5
0
5
10
Question1I: Differential expression
How many samples per group and at what coverage
should I sequence to get a desired number of
differentially expressed genes(DEG)?
Friday 8 May 15
Publicly available data
Dataset A
We found a dataset consisting of 6 samples (3 for
control and 3 for condition) sequenced at low
coverage in a MIseq Illumina sequencer.
A follow up dataset was generated with high
coverage from a HIseq Illumina sequencer for the
same conditions
Friday 8 May 15
Publicly available data
Dataset B
Well know MAQC samples (human brain vs pooled
human tissues) were generated in 5 technical
replicates with high coverage in HIseq Illumina
sequencer.
Friday 8 May 15
Simulation setup
1. Compute relative expressions and distributions for a
set of samples from pilot data (control vs condition)
2. Simulate 3 combinations of parameters:
Mean of
fragment’s
length
Friday 8 May 15
Read length
Total reads
300
101
16M
300
101
32M
150
750
1.8M
Simulation setup
3. Simulate 3 and 6 samples for each group *
4. Compute number of DEG genes for pilot and
simulated data combined
5. Compare to number of DEG genes from real data
(*) We simulate new samples following a LNNMV model for each of the group’s expression per
transcript.
Friday 8 May 15
Simulation setup
(*) To simulate the expressions of new samples we use
the lognormal-normal with modified variance model
(LNNMV, Yuan and Kendiorski (2006)).
This model correctly fits the data as was seen from
whole genome quantile plots and asymmetry checks
Friday 8 May 15
500
400
300
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
100
200
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
●
0
DE calls (FC>3, TREAT BH < 0.05)
600
Results: DEG genes dataset A
3
Short reads (r=101,N=16m)
Short reads (r=101,N=32m)
Long reads (r=750,N=1.8m)
6
Sample size per group
Friday 8 May 15
9
30000
20000
10000
Observed
Simulated
0
DE calls (FC>3, TREAT BH < 0.05)
40000
Results: DEG genes dataset B
2
3
4
Sample size per group
Friday 8 May 15
5
Implications
Prediction
Accuracy in the expression
estimation depends on on the
organism and tissue
Shorter reads (but more) are
better to estimate expression
Fold changes between groups
are unknown
DEG genes are gained when
adding more samples to an
existing dataset and not by
increasing the number of reads
per sample
Consequence
no general recommendations are
valid
Don’t be fooled
The tendency of increasing read
Get better results at the same
length may not be optimal for
cost
RNAseq
sample size calculation is
impossible without a pilot
Sequence more samples, not
reads
No more DEG are gained when
adding more samples to an
Do not sequence more
existing dataset
Friday 8 May 15
Benefits
Don’t be fooled!
Spend money for a benefit
Do not spend money
Conclusions
• With the advances in technology in biology little
importance has been given to the optimal use of
resources
• Almost no research has been done on sample size
calculation
• Researchers believe that money=results... oh my
my
• Batch and technical effects are rarely taken into
account leading to no or wrong results
Friday 8 May 15
Bioconductor package: casper
http://www.bioconductor.org/packages/2.12/bioc/html/casper.html
Rossell D., Stephan-Otto Attolini C., Kroiss M.,
Stöcker A. (2014) Quantifying alternative
splicing from paired-end RNA-seq data. Annals
of Applied Statistics, 8:1, 309-330.
Size calculations:
C. Stephan-Otto Attolini, V. Peña and D. Rossell.
(submitted)
Friday 8 May 15
Joint work with:
David Rossell, IRB
Manuel Kroiss, Almond Stocker, Ludwig Maximilians
Universitaet
Victor Peña, University of Duke
Thank you
Friday 8 May 15
Download