DMR Finding

advertisement
Methylation Calling
To call methylated sites, we summed the number of reads that supported methylation at a site
and the number of reads that did not. We used these counts to perform a binomial test with a
probability of success equal to the non-conversion rate, which was determined by computing the
fraction of methylated reads in the lambda genome (spiked in during library construction). The
false discovery rate (FDR) for a given p-value cutoff was computed by calculating the fraction of
sites in the lambda genome that had a p-value less than or equal to the cutoff and then dividing
that quantity by the fraction of sites that had a p-value less than or equal to the cutoff across all
other chromosomes. Because the p-value distributions for each methylation context are
different, this procedure was applied to each three nucleotide context independently (e.g., a pvalue cutoff was calculated for CAT cytosines).
DMR Finding
We defined a stochastic model of our methylation data sets in which the observed number of
reads supporting methylated and unmethylated cytosines at each position in each sample is
drawn from a binomial distribution. In each sample at each cytosine in the CG context there is a
single parameter, 𝑥𝑛𝑖 , corresponding to the true fraction of methylated alleles in the population,
or the methylation level, where i denotes the position of cytosine and n denotes the sample. Our
null hypothesis is that the methylation level at this position is equal in all samples (𝑥𝑛𝑖 = 𝑥 𝑖 for all
n). Our procedure is designed to test whether the observed data are consistent with the null
hypothesis, or alternatively if there is a significant deviation from equal methylation levels.
To do this, first we compute a goodness-of-fit statistic, s, which was introduced and
validated by Perkins et al.5. Specifically, we arrange the observed data in an Nx2 table, with one
row for each of N samples and a column for reads supporting methylated and unmethylated
𝑖
cytosines respectively. The number of observed reads in sample n at position i is 𝑜𝑛𝑗
, where j =
1 for methylated reads and j = 2 for unmethylated reads. The expected number of reads in
𝑖
sample n with methylation state j under the null hypothesis is 𝑒𝑛𝑗
:
𝑁
𝑖
𝑒𝑛𝑗
=
2
𝑖
𝑖
( ∑ 𝑜𝑚𝑗 ) (∑ 𝑜𝑛𝑘
) /𝑀𝑖
𝑚=1
𝑘=1
2
𝑖
where 𝑀𝑖 = ∑𝑁
𝑛=1 ∑𝑘=1 𝑜𝑛𝑘 is the total number of reads in all samples. The statistic for the
goodness of fit is
𝑁
2
1
𝑖
𝑖 2
𝑠 =√
∑ ∑(𝑜𝑛𝑗
− 𝑒𝑛𝑗
)
2𝑁
𝑖
𝑛=1 𝑗=1
Next, we simulated read count data under our stochastic model assuming the null hypothesis in
the following way:

Set all cell counts in the table to zero

Randomly select a cell in the table with probability equal to the expected counts divided
by the total number of counts in the table (
𝑖
𝑒𝑛𝑗
𝑀𝑖
). Increment the value in this cell by one.

Repeat this procedure 𝑀𝑖 times.

𝑖
Finally, calculate the value of the statistic, 𝑠𝑠ℎ𝑢𝑓𝑓
, for the randomly generated table.
This randomization procedure was repeated until we observed 100 iterations with a value of
𝑖
𝑠𝑠ℎ𝑢𝑓𝑓
that was at least as extreme as that of the observed data, s, up to a maximum of 3,000
iterations. The p-value at position i was then computed as:
𝑝𝑖 =
𝑅𝑖 + 1
𝑇𝑖
Where Ri is the number of randomized tables with a statistic greater than or equal to the original
table’s statistic and Ti is the total number of randomized tables that were computed. Our
adaptive permutation procedure ensures that any sites which we may potentially identify as
significantly differentially methylated with 𝑝𝑖 < 0.01 will be sampled 3,000 times. At other sites,
we have observed an appreciable number (100) of permutations more extreme than our original
test statistic (s≥sshuff) and the p-value for these sites will be p ≥ (100+1)/3000 = 0.034; these
sites will therefore not be called as differentially methylated.
To control the false discovery rate (FDR) at our desired rate of 1%, we used a
computationally efficient procedure designed for comparing multiple sequential permutationderived p-values6. This procedure is designed to account for the effect of our adaptive
permutation procedure on the form of the distribution of p-values. First we generated a
histogram of the p-values across all cytosines in CG context. We also calculated the expected
number of p-values to fall in a particular bin under the null hypothesis. This expected count is
computed by multiplying the width of the bin by the current estimate for the number of true null
hypotheses (m0), which is initialized to the number of tests performed. We then identified the
first bin (starting from the most significant bin) where the expected number of p-values is greater
than or equal to the observed value. The differences between the expected and observed
counts in all the bins up to this point are summed, and a new estimate of m0 is generated by
subtracting this sum from the current total number of tests. This procedure was iterated until
convergence, which we defined as a change in the m0 estimate less than or equal to 0.01. With
this m0 estimate, we were able to estimate the FDR corresponding to a given p-value cutoff by
multiplying the p-value by the m0 estimate (the expected number of positives at that cutoff under
the null hypothesis) and dividing that product by the total number of significant tests we detected
at that p-value cutoff. We chose the largest p-value cutoff that still satisfied our FDR
requirement.
In the next stage of analysis, we combined significant sites (DMSs) into blocks if they
were within 250 bases of one another and had methylation changes in the same direction (e.g.,
sample A was hypermethylated and sample B was hypomethylated at both sites). A sample was
considered hypo or hyper methylated if the deviation of observed counts from the expected
counts was in the top or bottom 1% of deviations. These residuals were calculated for a position
i using the following formula for a given cell in row n and column j of the table:
𝑖
𝑖
𝑜𝑛𝑗
− 𝑒𝑛𝑗
√𝑒 𝑖 ∗ (1 − ∑𝑁
𝑚=1
𝑛𝑗
𝑖
𝑒𝑚𝑗
𝑒𝑖
) ∗ (1 − ∑2𝑘=1 𝑛𝑘𝑖 )
𝑖
𝑀
𝑀
The distinction between hypermethylation and hypomethylation was made based on the sign of
the residuals. For example, if the residual for the methylated read count of sample A was
positive, it was counted as hypermethylation. Furthermore, blocks that contained fewer than 10
differentially methylated sites were discarded.
Download