Skip to content
Snippets Groups Projects
Commit 8e161baa authored by hjmegens's avatar hjmegens
Browse files

tutorial

parent 8fc961c6
No related branches found
No related tags found
No related merge requests found
...@@ -18,6 +18,12 @@ the files you need: ...@@ -18,6 +18,12 @@ the files you need:
SESSIONDIR=/home/formacion/COMUNES/IAMZ/data/CIHEAM/sessions/variant_annotation SESSIONDIR=/home/formacion/COMUNES/IAMZ/data/CIHEAM/sessions/variant_annotation
~~~~ ~~~~
And make sure python3 can be found:
~~~~ {.bash}
alias python3='/home/formacion/COMUNES/IAMZ/soft/python-3.4.2/bin/python3.4'
~~~~
### Slicing and dicing of VCF files ### Slicing and dicing of VCF files
VCF files can get very big. Being able to manipulate them and extract VCF files can get very big. Being able to manipulate them and extract
...@@ -28,7 +34,7 @@ called variants of chromosome 18, bgzip-ping them on-the-fly, and then ...@@ -28,7 +34,7 @@ called variants of chromosome 18, bgzip-ping them on-the-fly, and then
indexing that file with tabix: indexing that file with tabix:
~~~~ {.bash} ~~~~ {.bash}
tabix -h /home/formacion/COMUNES/IAMZ/data/CIHEAM/MULTISAMPLE_VCF/allbt.vcf.gz 18 | bgzip >BT18.vcf.gz tabix -h $SESSIONDIR/allbt.vcf.gz 18 | bgzip >BT18.vcf.gz
tabix -p vcf BT18.vcf.gz tabix -p vcf BT18.vcf.gz
~~~~ ~~~~
......
...@@ -34,9 +34,11 @@ code > span.er { color: #ff0000; font-weight: bold; } ...@@ -34,9 +34,11 @@ code > span.er { color: #ff0000; font-weight: bold; }
<span class="kw">cd</span> annotation_session</code></pre> <span class="kw">cd</span> annotation_session</code></pre>
<p>Create an Env.Var. to the communal session directory that holds some of the files you need:</p> <p>Create an Env.Var. to the communal session directory that holds some of the files you need:</p>
<pre class="sourceCode bash"><code class="sourceCode bash"><span class="ot">SESSIONDIR=</span>/home/formacion/COMUNES/IAMZ/data/CIHEAM/sessions/variant_annotation</code></pre> <pre class="sourceCode bash"><code class="sourceCode bash"><span class="ot">SESSIONDIR=</span>/home/formacion/COMUNES/IAMZ/data/CIHEAM/sessions/variant_annotation</code></pre>
<p>And make sure python3 can be found:</p>
<pre class="sourceCode bash"><code class="sourceCode bash"><span class="kw">alias</span> python3=<span class="st">&#39;/home/formacion/COMUNES/IAMZ/soft/python-3.4.2/bin/python3.4&#39;</span></code></pre>
<h3 id="slicing-and-dicing-of-vcf-files">Slicing and dicing of VCF files</h3> <h3 id="slicing-and-dicing-of-vcf-files">Slicing and dicing of VCF files</h3>
<p>VCF files can get very big. Being able to manipulate them and extract relevant information is important. In practice, flat text files such as VCF are currently the basis for further analysis - see the Imputation and Population practical sessions. The first task involves selecting all called variants of chromosome 18, bgzip-ping them on-the-fly, and then indexing that file with tabix:</p> <p>VCF files can get very big. Being able to manipulate them and extract relevant information is important. In practice, flat text files such as VCF are currently the basis for further analysis - see the Imputation and Population practical sessions. The first task involves selecting all called variants of chromosome 18, bgzip-ping them on-the-fly, and then indexing that file with tabix:</p>
<pre class="sourceCode bash"><code class="sourceCode bash"><span class="kw">tabix</span> -h /home/formacion/COMUNES/IAMZ/data/CIHEAM/MULTISAMPLE_VCF/allbt.vcf.gz 18 <span class="kw">|</span> <span class="kw">bgzip</span> <span class="kw">&gt;</span>BT18.vcf.gz <pre class="sourceCode bash"><code class="sourceCode bash"><span class="kw">tabix</span> -h <span class="ot">$SESSIONDIR</span>/allbt.vcf.gz 18 <span class="kw">|</span> <span class="kw">bgzip</span> <span class="kw">&gt;</span>BT18.vcf.gz
<span class="kw">tabix</span> -p vcf BT18.vcf.gz</code></pre> <span class="kw">tabix</span> -p vcf BT18.vcf.gz</code></pre>
<p>Have a look at what is inside this file:</p> <p>Have a look at what is inside this file:</p>
<pre class="sourceCode bash"><code class="sourceCode bash"><span class="kw">gunzip</span> -c BT18.vcf.gz <span class="kw">|</span> <span class="kw">grep</span> -v <span class="st">&#39;^##&#39;</span> <span class="kw">|</span> <span class="kw">more</span></code></pre> <pre class="sourceCode bash"><code class="sourceCode bash"><span class="kw">gunzip</span> -c BT18.vcf.gz <span class="kw">|</span> <span class="kw">grep</span> -v <span class="st">&#39;^##&#39;</span> <span class="kw">|</span> <span class="kw">more</span></code></pre>
......
...@@ -13,13 +13,17 @@ Create an Env.Var. to the communal session directory that holds some of the file ...@@ -13,13 +13,17 @@ Create an Env.Var. to the communal session directory that holds some of the file
<source lang='bash'> <source lang='bash'>
SESSIONDIR=/home/formacion/COMUNES/IAMZ/data/CIHEAM/sessions/variant_annotation SESSIONDIR=/home/formacion/COMUNES/IAMZ/data/CIHEAM/sessions/variant_annotation
</source> </source>
And make sure python3 can be found:
<source lang='bash'>
alias python3='/home/formacion/COMUNES/IAMZ/soft/python-3.4.2/bin/python3.4'
</source>
=== Slicing and dicing of VCF files === === Slicing and dicing of VCF files ===
VCF files can get very big. Being able to manipulate them and extract relevant information is important. In practice, flat text files such as VCF are currently the basis for further analysis - see the Imputation and Population practical sessions. The first task involves selecting all called variants of chromosome 18, bgzip-ping them on-the-fly, and then indexing that file with tabix: VCF files can get very big. Being able to manipulate them and extract relevant information is important. In practice, flat text files such as VCF are currently the basis for further analysis - see the Imputation and Population practical sessions. The first task involves selecting all called variants of chromosome 18, bgzip-ping them on-the-fly, and then indexing that file with tabix:
<source lang='bash'> <source lang='bash'>
tabix -h /home/formacion/COMUNES/IAMZ/data/CIHEAM/MULTISAMPLE_VCF/allbt.vcf.gz 18 | bgzip >BT18.vcf.gz tabix -h $SESSIONDIR/allbt.vcf.gz 18 | bgzip >BT18.vcf.gz
tabix -p vcf BT18.vcf.gz tabix -p vcf BT18.vcf.gz
</source> </source>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment