Skip to content

Commit

Permalink
Update bcftools/roh and roh-viz documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
pd3 committed Dec 28, 2024
1 parent 68f13f2 commit e2815b4
Show file tree
Hide file tree
Showing 4 changed files with 188 additions and 15 deletions.
82 changes: 76 additions & 6 deletions doc/bcftools.1
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
.\" Title: bcftools
.\" Author: [see the "AUTHOR(S)" section]
.\" Generator: Asciidoctor 2.0.15.dev
.\" Date: 2024-12-16
.\" Date: 2024-12-28
.\" Manual: \ \&
.\" Source: \ \&
.\" Language: English
.\"
.TH "BCFTOOLS" "1" "2024-12-16" "\ \&" "\ \&"
.TH "BCFTOOLS" "1" "2024-12-28" "\ \&" "\ \&"
.ie \n(.g .ds Aq \(aq
.el .ds Aq '
.ss \n[.ss] 0
Expand Down Expand Up @@ -51,7 +51,7 @@ standard input (stdin) and outputs to the standard output (stdout). Several
commands can thus be combined with Unix pipes.
.SS "VERSION"
.sp
This manual page was last updated \fB2024\-12\-16 09:31 GMT\fP and refers to bcftools git version \fB1.21\-58\-g6559a12a+\fP.
This manual page was last updated \fB2024\-12\-28 22:19 GMT\fP and refers to bcftools git version \fB1.21\-61\-g68f13f2e+\fP.
.SS "BCF1"
.sp
The obsolete BCF1 format output by versions of samtools <= 0.1.19 is \fBnot\fP
Expand Down Expand Up @@ -347,7 +347,7 @@ Some helper scripts are bundled with the bcftools code.
. sp -1
. IP \(bu 2.3
.\}
\fBgff2gff\fP .. converts a GFF file to the format required by \fBcsq\fP
\fBgff2gff\fP .. converts a GFF file to the format required by \fBbcftools csq\fP
.RE
.sp
.RS 4
Expand All @@ -358,7 +358,18 @@ Some helper scripts are bundled with the bcftools code.
. sp -1
. IP \(bu 2.3
.\}
\fBplot\-vcfstats\fP .. plots the output of \fBstats\fP
\fBplot\-vcfstats\fP .. plots the output of \fBbcftools stats\fP
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
. sp -1
. IP \(bu 2.3
.\}
\fBroh\-viz\fP .. creates HTML/JavaScript visualization of \fBbcftools roh\fP
.RE
.SH "COMMANDS AND OPTIONS"
.SS "Common Options"
Expand Down Expand Up @@ -5079,7 +5090,8 @@ see \fBCommon Options\fP
.SS "bcftools roh [\fIOPTIONS\fP] \fIfile.vcf.gz\fP"
.sp
A program for detecting runs of homo/autozygosity. Only bi\-allelic sites
are considered.
are considered. The results can be visualized in HTML/JavaScript using
the \fBroh\-viz\fP script.
.SS "The HMM model:"
.sp
.if n .RS 4
Expand Down Expand Up @@ -5836,6 +5848,64 @@ cd outdir && python plot.py && pdflatex summary.tex
.fam
.fi
.if n .RE
.SS "roh\-viz [\fIOPTIONS\fP]"
.sp
Script for visualizing the output of \fBbcftools roh\fP. It creates
a HTML/JavaScript document which can be interactively viewed in your favorite
web browser.
.sp
\fB\-i, \-\-RoH\-file\fP \fIFILE\fP
.RS 4
Output of bcftools/roh
.RE
.sp
\fB\-l, \-\-min\-length\fP \fINUM\fP
.RS 4
Mimimum length of ROH [1e6]
.RE
.sp
\fB\-o, \-\-output\fP \fIFILE\fP
.RS 4
HTML output file
.RE
.sp
\fB\-r, \-\-regions\fP \fILIST\fP
.RS 4
List of chromosomes/regions
.RE
.sp
\fB\-s, \-\-samples\fP \fILIST\fP
.RS 4
List of samples to show
.RE
.sp
\fB\-v, \-\-VCF\-file\fP \fIFILE\fP
.RS 4
VCF file to determine homozygosity rate
.RE
.sp
\fB\-h, \-?, \-\-help\fP
This help message
.sp
\fBExample:\fP
.sp
.if n .RS 4
.nf
.fam C
# Find RoH regions
bcftools roh \-\-AF\-dflt 0.5 \-G 30 \-Or \-o roh.txt file.bcf
.fam
.fi
.if n .RE
.sp
.if n .RS 4
.nf
.fam C
# Create HTML/JavaScript visualization
roh\-viz \-r roh.txt \-v file.bcf \-o output.html
.fam
.fi
.if n .RE
.SH "FILTERING EXPRESSIONS"
.sp
These filtering expressions are accepted by most of the commands.
Expand Down
73 changes: 68 additions & 5 deletions doc/bcftools.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ <h2 id="_description">DESCRIPTION</h2>
<div class="sect2">
<h3 id="_version">VERSION</h3>
<div class="paragraph">
<p>This manual page was last updated <strong>2024-12-16 09:31 GMT</strong> and refers to bcftools git version <strong>1.21-58-g6559a12a+</strong>.</p>
<p>This manual page was last updated <strong>2024-12-28 22:19 GMT</strong> and refers to bcftools git version <strong>1.21-61-g68f13f2e+</strong>.</p>
</div>
</div>
<div class="sect2">
Expand Down Expand Up @@ -178,10 +178,13 @@ <h2 id="_list_of_scripts">LIST OF SCRIPTS</h2>
<div class="ulist">
<ul>
<li>
<p><strong><a href="#gff2gff">gff2gff</a></strong> .. converts a GFF file to the format required by <strong><a href="#csq">csq</a></strong></p>
<p><strong><a href="#gff2gff">gff2gff</a></strong> .. converts a GFF file to the format required by <strong><a href="#csq">bcftools csq</a></strong></p>
</li>
<li>
<p><strong><a href="#plot-vcfstats">plot-vcfstats</a></strong> .. plots the output of <strong><a href="#stats">stats</a></strong></p>
<p><strong><a href="#plot-vcfstats">plot-vcfstats</a></strong> .. plots the output of <strong><a href="#stats">bcftools stats</a></strong></p>
</li>
<li>
<p><strong><a href="#roh-viz">roh-viz</a></strong> .. creates HTML/JavaScript visualization of <strong><a href="#roh">bcftools roh</a></strong></p>
</li>
</ul>
</div>
Expand Down Expand Up @@ -4380,7 +4383,8 @@ <h3 id="reheader">bcftools reheader [<em>OPTIONS</em>] <em>file.vcf.gz</em></h3>
<h3 id="roh">bcftools roh [<em>OPTIONS</em>] <em>file.vcf.gz</em></h3>
<div class="paragraph">
<p>A program for detecting runs of homo/autozygosity. Only bi-allelic sites
are considered.</p>
are considered. The results can be visualized in HTML/JavaScript using
the <strong><a href="#roh-viz">roh-viz</a></strong> script.</p>
</div>
<div class="sect3">
<h4 id="_the_hmm_model">The HMM model:</h4>
Expand Down Expand Up @@ -5114,6 +5118,65 @@ <h3 id="plot-vcfstats">plot-vcfstats [<em>OPTIONS</em>] <em>file.vchk</em> [&#82
</div>
</div>
</div>
<div class="sect2">
<h3 id="roh-viz">roh-viz [<em>OPTIONS</em>]</h3>
<div class="paragraph">
<p>Script for visualizing the output of <strong><a href="#roh">bcftools roh</a></strong>. It creates
a HTML/JavaScript document which can be interactively viewed in your favorite
web browser.</p>
</div>
<div class="dlist">
<dl>
<dt class="hdlist1"><strong>-i, --RoH-file</strong> <em>FILE</em></dt>
<dd>
<p>Output of bcftools/roh</p>
</dd>
<dt class="hdlist1"><strong>-l, --min-length</strong> <em>NUM</em></dt>
<dd>
<p>Mimimum length of ROH [1e6]</p>
</dd>
<dt class="hdlist1"><strong>-o, --output</strong> <em>FILE</em></dt>
<dd>
<p>HTML output file</p>
</dd>
<dt class="hdlist1"><strong>-r, --regions</strong> <em>LIST</em></dt>
<dd>
<p>List of chromosomes/regions</p>
</dd>
<dt class="hdlist1"><strong>-s, --samples</strong> <em>LIST</em></dt>
<dd>
<p>List of samples to show</p>
</dd>
<dt class="hdlist1"><strong>-v, --VCF-file</strong> <em>FILE</em></dt>
<dd>
<p>VCF file to determine homozygosity rate</p>
</dd>
</dl>
</div>
<div class="paragraph">
<p><strong>-h, -?, --help</strong>
This help message</p>
</div>
<div class="paragraph">
<p><strong>Example:</strong></p>
</div>
<div class="openblock">
<div class="content">
<div class="literalblock">
<div class="content">
<pre># Find RoH regions
bcftools roh --AF-dflt 0.5 -G 30 -Or -o roh.txt file.bcf</pre>
</div>
</div>
<div class="literalblock">
<div class="content">
<pre># Create HTML/JavaScript visualization
roh-viz -r roh.txt -v file.bcf -o output.html</pre>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="sect1">
Expand Down Expand Up @@ -5654,7 +5717,7 @@ <h2 id="_copying">COPYING</h2>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-12-16 09:31:50 UTC
Last updated 2024-12-28 22:19:33 UTC
</div>
</div>
</body>
Expand Down
46 changes: 43 additions & 3 deletions doc/bcftools.txt
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,9 @@ LIST OF SCRIPTS
---------------
Some helper scripts are bundled with the bcftools code.

- *<<gff2gff,gff2gff>>* .. converts a GFF file to the format required by *<<csq,csq>>*
- *<<plot-vcfstats,plot-vcfstats>>* .. plots the output of *<<stats,stats>>*
- *<<gff2gff,gff2gff>>* .. converts a GFF file to the format required by *<<csq,bcftools csq>>*
- *<<plot-vcfstats,plot-vcfstats>>* .. plots the output of *<<stats,bcftools stats>>*
- *<<roh-viz,roh-viz>>* .. creates HTML/JavaScript visualization of *<<roh,bcftools roh>>*


COMMANDS AND OPTIONS
Expand Down Expand Up @@ -3286,7 +3287,8 @@ Modify header of VCF/BCF files, change sample names.
[[roh]]
=== bcftools roh ['OPTIONS'] 'file.vcf.gz'
A program for detecting runs of homo/autozygosity. Only bi-allelic sites
are considered.
are considered. The results can be visualized in HTML/JavaScript using
the *<<roh-viz,roh-viz>>* script.

==== The HMM model:
--------------------------------------
Expand Down Expand Up @@ -3829,6 +3831,44 @@ chromosome separately), plots graphs and creates a PDF presentation.
--


[[roh-viz]]
=== roh-viz ['OPTIONS']
Script for visualizing the output of *<<roh,bcftools roh>>*. It creates
a HTML/JavaScript document which can be interactively viewed in your favorite
web browser.

*-i, --RoH-file* 'FILE'::
Output of bcftools/roh

*-l, --min-length* 'NUM'::
Mimimum length of ROH [1e6]

*-o, --output* 'FILE'::
HTML output file

*-r, --regions* 'LIST'::
List of chromosomes/regions

*-s, --samples* 'LIST'::
List of samples to show

*-v, --VCF-file* 'FILE'::
VCF file to determine homozygosity rate

*-h, -?, --help*
This help message


*Example:*
--
# Find RoH regions
bcftools roh --AF-dflt 0.5 -G 30 -Or -o roh.txt file.bcf

# Create HTML/JavaScript visualization
roh-viz -r roh.txt -v file.bcf -o output.html
--


[[expressions]]
FILTERING EXPRESSIONS
---------------------
Expand Down
2 changes: 1 addition & 1 deletion misc/roh-viz
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ sub error
" -v, --VCF-file FILE VCF file to determine homozygosity rate\n",
" -h, -?, --help This help message\n",
"Example:\n",
" bcftools roh --AF-dflt 0.5 -G 30 -Or -o roh.txt file.bcf",
" bcftools roh --AF-dflt 0.5 -G 30 -Or -o roh.txt file.bcf\n",
" roh-viz -r roh.txt -v file.bcf -o output.html\n",
"\n";
exit -1;
Expand Down

0 comments on commit e2815b4

Please sign in to comment.