Skip to content

Commit

Permalink
fix inlineMath vs displayMath
Browse files Browse the repository at this point in the history
  • Loading branch information
philippadoherty committed Nov 28, 2023
1 parent da63bb0 commit 147287e
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 20 deletions.
3 changes: 2 additions & 1 deletion _layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
<script>
MathJax = {
tex: {
inlineMath: [['$$', '$$'], ['\\(', '\\)']]
inlineMath: [['$', '$'], ['\\(', '\\)']],
displayMath: [['$$', '$$'], ['\\[', '\\]']]
},
svg: {
fontCache: 'global'
Expand Down
2 changes: 1 addition & 1 deletion docs/Advanced_Step-by-step_Peak_Calling.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ control.

The whole genome background can be calculated as
`the_number_of_control_reads\fragment_length/genome_size`, and in our
example, it is $$199867*254/2700000000 ~= .0188023$$. You don\'t need to
example, it is $199867*254/2700000000 ~= .0188023$. You don\'t need to
run subcommands to build a genome background track since it\'s just a
single value.

Expand Down
4 changes: 2 additions & 2 deletions docs/bdgdiff.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ The likelihood function we used while comparing two conditions: ChIP

$$ln(LR) = x*(ln(x)-ln(y)) + y - x$$

Here $$LR$$ is the likelihood ratio, x is the signal (fragment pileup)
Here $LR$ is the likelihood ratio, x is the signal (fragment pileup)
we observed in condition 1, and y is the signal in condition
2. And $$ln$$ is the natural logarithm.
2. And $ln$ is the natural logarithm.

Note: All regions on the same chromosome in the bedGraph file should
be continuous so only bedGraph files from MACS3 are acceptable.
Expand Down
32 changes: 16 additions & 16 deletions docs/callvar.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,37 +157,37 @@ likelihood functions of ChIP and control data:

$$L(\omega,\phi,g_c,g_i:D)=L(\omega,g_c:D_c)L(\phi,g_i:D_i)$$

where $$D_c$$ and $$D_i$$ represent the ChIP-Seq and control (e.g.,
where $D_c$ and $D_i$ represent the ChIP-Seq and control (e.g.,
genomic input) data observed at the position including base coverage
and base qualities. The parameter $$\omega$$ stands for the allele ratio
and base qualities. The parameter $\omega$ stands for the allele ratio
of allele A (chosen as the more abundant or stronger allele compared
with the others) from the ChIP-Seq data and $$\phi$$ represents the
allele ratio in the control. The parameter $$g_c$$ represents the
with the others) from the ChIP-Seq data and $\phi$ represents the
allele ratio in the control. The parameter $g_c$ represents the
actual number of ChIPed DNA fragments containing allele A, which could
differ from the observed count $$r_{c,A}$$ considering that some
observations could be due to sequencing errors. The symbol $$g_i$$
represents the control analogously to $$g_c$$. We use $$r_c$$ to
denote the total number of observed allele A ($$r_{c,A}$$) and allele
B ($$r_{c,B}$$). We assume the occurrence of the allele A ($$g_c$$)
is from a Bernoulli trial from $$r_c$$ with the allele ratio
$$\omega$$. The probability of observing the ChIP-Seq data at a certain
differ from the observed count $r_{c,A}$ considering that some
observations could be due to sequencing errors. The symbol $g_i$
represents the control analogously to $g_c$. We use $r_c$ to
denote the total number of observed allele A ($r_{c,A}$) and allele
B ($r_{c,B}$). We assume the occurrence of the allele A ($g_c$)
is from a Bernoulli trial from $r_c$ with the allele ratio
$\omega$. The probability of observing the ChIP-Seq data at a certain
position under a given type is as follows:


$$Pr(D_c|g_c,\omega) = Pr(D_c|g_c) =
\sum^{r_{c,A}}_{j=1}\left((1-\epsilon_j)g_c/r_c+\epsilon_j(1-g_c/r_c)\right)\sum_{j=1}^{r_{c,B}}\left((1-\epsilon_j)(1-g_c/r_c)+\epsilon_j
g_c/r_c\right)$$

where $$\epsilon_j$$ represents the sequencing error of the base
where $\epsilon_j$ represents the sequencing error of the base
showing difference with reference genome in case of mismatch
(corresponding to SNV) and insertion. In case of deletion, the
sequencing errors from the two bases on sequenced read surrounding the
deletion would be considered. We model the control data in the similar
way. We assess the likelihood functions of the 4 major type using the
following parameters: $$\omega=1,\phi=1,g_c=r_{c,0},g_i=r_{i,0}$$ for
A/A genotype; $$\omega=0,\phi=0,g_c=0,g_i=0$$ for B/B genotype,
$$\omega=0.5,\phi=0.5$$ and $$g_c,g_i$$ as free variables for A/B
genotype with unbiased binding; $$\phi=0.5$$ and $$\omega,g_c,g_i$$ as
following parameters: $\omega=1,\phi=1,g_c=r_{c,0},g_i=r_{i,0}$ for
A/A genotype; $\omega=0,\phi=0,g_c=0,g_i=0$ for B/B genotype,
$\omega=0.5,\phi=0.5$ and $g_c,g_i$ as free variables for A/B
genotype with unbiased binding; $\phi=0.5$ and $\omega,g_c,g_i$ as
free variables for A/B genotype with biased binding or allele
usage. Next, we apply the Bayesian Information Criterion (BIC) to
select the best type as our prediction with the minimal BIC value
Expand Down

0 comments on commit 147287e

Please sign in to comment.