<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://teaching.healthtech.dtu.dk/22126/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Mick</id>
	<title>22126 - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://teaching.healthtech.dtu.dk/22126/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Mick"/>
	<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php/Special:Contributions/Mick"/>
	<updated>2026-05-04T19:32:50Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_part_2&amp;diff=616</id>
		<title>SNP calling exercise part 2</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_part_2&amp;diff=616"/>
		<updated>2026-01-17T16:20:11Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Filtering&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We have seen that the VCF contains some low-quality or unreliable variant calls. Before downstream analyses, we generally want to &amp;lt;b&amp;gt;remove poor-quality sites&amp;lt;/b&amp;gt; or annotate them so they can be excluded later. In this exercise we explore how to apply &amp;lt;b&amp;gt;hard filters&amp;lt;/b&amp;gt; and how to remove variants in regions of poor mappability.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please use the VCF file generated in Part 1.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Hard Filtering&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Soft filtering approaches (e.g. VQSR) attempt to statistically learn which variants are “true.” However, these approaches require large cohorts or population-level resources, which may not exist for many organisms or under-sampled populations. For this reason, we often fall back on &amp;lt;b&amp;gt;hard filtering&amp;lt;/b&amp;gt;, i.e. applying fixed cutoffs.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Hard filtering is simple but may introduce bias if the filter correlates with variant type (e.g. heterozygous sites often have lower depth). Filters should be chosen thoughtfully.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use the following genomic mask file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/databases/databases/GRCh38/mask99.bed.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This file is in the &amp;lt;b&amp;gt;BED interval format&amp;lt;/b&amp;gt;, which stores genomic regions as:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chromosome   start(0-based)   end(1-based)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;0-based&amp;lt;/b&amp;gt;: first base has coordinate 0&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;1-based&amp;lt;/b&amp;gt;: first base has coordinate 1&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This mask contains genomic regions to &amp;lt;b&amp;gt;exclude&amp;lt;/b&amp;gt; (often low-quality or repetitive regions). Because most genotypers do not recognize duplicated regions, combining hard filtering with mappability filters is best practice.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;A typical hard-filtering command using GATK is:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk VariantFiltration \&lt;br /&gt;
   -V [INPUT VCF] \&lt;br /&gt;
   -O [OUTPUT VCF] \&lt;br /&gt;
   -filter &amp;quot;DP &amp;lt; 10.0&amp;quot;   --filter-name &amp;quot;DP&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;QUAL &amp;lt; 30.0&amp;quot; --filter-name &amp;quot;QUAL30&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;SOR &amp;gt; 3.0&amp;quot;   --filter-name &amp;quot;SOR3&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;FS &amp;gt; 60.0&amp;quot;   --filter-name &amp;quot;FS60&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;MQ &amp;lt; 40.0&amp;quot;   --filter-name &amp;quot;MQ40&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Explanation of filters:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table class=&amp;quot;wikitable&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;Filter&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;Meaning&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;DP &amp;amp;lt; 10&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove sites with &amp;amp;lt;10× coverage&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;QUAL &amp;amp;lt; 30&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove sites where variant quality &amp;amp;lt;30  &lt;br /&gt;
      (variant QUAL ≠ genotype quality GQ — explanation:  &lt;br /&gt;
      [https://gatk.broadinstitute.org/hc/en-us/articles/360035531392 Variant QUAL vs GQ])&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;SOR &amp;amp;gt; 3.0&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove sites with strong strand bias  &lt;br /&gt;
      ([https://gatk.broadinstitute.org/hc/en-us/articles/360036361772 StrandOddsRatio])&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;FS &amp;amp;gt; 60&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove variants failing Fisher Strand bias test  &lt;br /&gt;
      ([https://gatk.broadinstitute.org/hc/en-us/articles/360036361992 FisherStrand])&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;MQ &amp;amp;lt; 40&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove sites where reads have low mapping quality&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; No filter is perfect — you should progressively add filters, evaluate their impact, and ensure that you do not introduce unwanted biases.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q1&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;How many sites were filtered out?  &lt;br /&gt;
Sites that pass all filters have &amp;lt;code&amp;gt;PASS&amp;lt;/code&amp;gt; in the 7th column. Use &amp;lt;code&amp;gt;grep&amp;lt;/code&amp;gt; to count PASS vs non-PASS entries.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q2&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;The 7th column contains the name(s) of the filters that failed.  &lt;br /&gt;
Using &amp;lt;code&amp;gt;cut&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;sort&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;uniq -c&amp;lt;/code&amp;gt;, determine which filter removed the most sites.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Filtering by Mappability&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we remove variants that fall inside &amp;lt;b&amp;gt;low-mappability regions&amp;lt;/b&amp;gt;, because reads cannot be uniquely mapped there and false positives are common.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use &amp;lt;b&amp;gt;bedtools intersect&amp;lt;/b&amp;gt; to retain only variants located in high-mappability intervals (≥99% unique mappability):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bedtools intersect -header \&lt;br /&gt;
   -a [INPUT VCF] \&lt;br /&gt;
   -b /home/databases/databases/GRCh38/filter99.bed.gz \&lt;br /&gt;
 | /home/ctools/htslib-1.20/bgzip -c &amp;gt; [OUTPUT VCF]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Name your output:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NA24694_hf_map99.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The &amp;quot;99&amp;quot; refers to the proportion of synthetic reads that map uniquely at that position.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q3&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;How many variants remain after removing low-mappability regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Annotation of Variants&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we examine the &amp;lt;b&amp;gt;genomic context&amp;lt;/b&amp;gt; of variants: intronic, exonic, intergenic, UTR, etc. We use &amp;lt;b&amp;gt;snpEff&amp;lt;/b&amp;gt; for variant annotation.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
java -jar /home/ctools/snpEff/snpEff.jar eff \&lt;br /&gt;
   -dataDir /home/databases/databases/snpEff/ \&lt;br /&gt;
   -htmlStats [OUTPUT HTML] \&lt;br /&gt;
   GRCh38.99 \&lt;br /&gt;
   [INPUT VCF] \&lt;br /&gt;
 | /home/ctools/htslib-1.20/bgzip -c &amp;gt; [OUTPUT VCF]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-dataDir&amp;lt;/code&amp;gt;: location of snpEff databases&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;GRCh38.99&amp;lt;/code&amp;gt;: genome version — must match the reference genome you used earlier&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run &amp;lt;code&amp;gt;snpEff&amp;lt;/code&amp;gt; on your hard-filtered VCF (before mappability filtering).&lt;br /&gt;
This produces:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HTML report: &amp;lt;code&amp;gt;NA24694_hf.html&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Annotated VCF: &amp;lt;code&amp;gt;NA24694_hf_ann.vcf.gz&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing the snpEff HTML report:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the HTML file directly from the&lt;br /&gt;
left-hand file panel.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML file to&lt;br /&gt;
your local computer and open it in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/NA24694_hf.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q4&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Which genomic region category contains the most variants (exon, intron, upstream, downstream, UTR, etc.)?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q5&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;How many variants are predicted to cause a &amp;lt;b&amp;gt;codon change&amp;lt;/b&amp;gt;?  &lt;br /&gt;
See explanations at: [https://en.wikipedia.org/wiki/Point_mutation Point mutation]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please find answers here:  [SNP_calling_exercise_part_2_answers SNP_calling_exercise_part_2_answers]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations — you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;i&amp;gt;Note:&amp;lt;/i&amp;gt; When piping &amp;lt;code&amp;gt;bcftools view&amp;lt;/code&amp;gt; into other tools, consider specifying the output type using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
-O {b|u|z|v}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This avoids unnecessary compression/decompression and speeds up workflows.&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=615</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=615"/>
		<updated>2026-01-15T14:36:26Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/7/77/Microbial_genomics_course22126_slide1-30_compressed.pdf Lecture slides 1-30])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-11:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:10pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/6/6d/Microbial_genomics_course22126_slide31-75_compressed.pdf Lecture slides 31-75])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; The same exercise page will be used throughout the day: ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 1 + exercise: Tree thinking ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1_Tree_thinking.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 2 + exercise: Data ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2_Data.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-11:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 3 + exercise: Basic methods ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3_Basic_methods.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00am-1:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 4 + exercise: Models and support ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4_Models_and_support.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 5 + exercise: Gene trees ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_5_Gene_trees.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:00am-3:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 6 + exercise: Molecular dating ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_6_MolecularDating.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Metabarcoding ([https://teaching.healthtech.dtu.dk/material/22126/2026/Metabarcoding_slides.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Metabarcoding ([https://github.com/leholman/25.DTUmetabarcodingExercise/blob/main/README.md Metabarcoding Exercises]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test.pdf Test])([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test_Answers.pdf Answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=614</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=614"/>
		<updated>2026-01-15T14:35:58Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/7/77/Microbial_genomics_course22126_slide1-30_compressed.pdf Lecture slides 1-30])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-11:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:10pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/6/6d/Microbial_genomics_course22126_slide31-75_compressed.pdf Lecture slides 31-75])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; The same exercise page will be used throughout the day: ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 1 + exercise: Tree thinking ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1_Tree_thinking.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 2 + exercise: Data ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2_Data.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-11:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 3 + exercise: Basic methods ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3_Basic_methods.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00am-1:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 4 + exercise: Models and support ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4_Models_and_support.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 5 + exercise: Gene trees ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_5_Gene_trees.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:00am-3:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 6 + exercise: Molecular dating ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_6_MolecularDating.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Metabarcoding ([https://teaching.healthtech.dtu.dk/material/22126/2026/Metabarcoding_slides.pdf Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Metabarcoding ([https://github.com/leholman/25.DTUmetabarcodingExercise/blob/main/README.md Metabarcoding Exercises]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test.pdf Test])([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test_Answers.pdf Answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=613</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=613"/>
		<updated>2026-01-15T14:35:12Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/7/77/Microbial_genomics_course22126_slide1-30_compressed.pdf Lecture slides 1-30])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-11:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:10pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/6/6d/Microbial_genomics_course22126_slide31-75_compressed.pdf Lecture slides 31-75])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; The same exercise page will be used throughout the day: ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 1 + exercise: Tree thinking ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1_Tree_thinking.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 2 + exercise: Data ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2_Data.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-11:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 3 + exercise: Basic methods ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3_Basic_methods.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00am-1:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 4 + exercise: Models and support ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4_Models_and_support.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 5 + exercise: Gene trees ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_5_Gene_trees.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:00am-3:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 6 + exercise: Molecular dating ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_6_MolecularDating.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Metabarcoding ([https://teaching.healthtech.dtu.dk/material/22126/2026/Metabarcoding_slides.pdf Lecture)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Metabarcoding ([https://github.com/leholman/25.DTUmetabarcodingExercise/blob/main/README.md Metabarcoding Exercises]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test.pdf Test])([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test_Answers.pdf Answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=612</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=612"/>
		<updated>2026-01-15T14:34:23Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/7/77/Microbial_genomics_course22126_slide1-30_compressed.pdf Lecture slides 1-30])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-11:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:10pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/6/6d/Microbial_genomics_course22126_slide31-75_compressed.pdf Lecture slides 31-75])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; The same exercise page will be used throughout the day: ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 1 + exercise: Tree thinking ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1_Tree_thinking.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 2 + exercise: Data ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2_Data.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-11:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 3 + exercise: Basic methods ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3_Basic_methods.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00am-1:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 4 + exercise: Models and support ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4_Models_and_support.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 5 + exercise: Gene trees ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_5_Gene_trees.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:00am-3:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 6 + exercise: Molecular dating ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_6_MolecularDating.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Metabarcoding ([https://teaching.healthtech.dtu.dk/material/22126/2026/Metabarcoding_slides.pdf Lecture)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([https://github.com/leholman/25.DTUmetabarcodingExercise/blob/main/README.md Metabarcoding Exercises]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test.pdf Test])([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test_Answers.pdf Answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=611</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=611"/>
		<updated>2026-01-14T12:20:48Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/7/77/Microbial_genomics_course22126_slide1-30_compressed.pdf Lecture slides 1-30])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-11:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:10pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: Use of next-generation (genome) sequencing in clinical microbiology ([https://teaching.healthtech.dtu.dk/22126/images/6/6d/Microbial_genomics_course22126_slide31-75_compressed.pdf Lecture slides 31-75])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; The same exercise page will be used throughout the day: ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 1 + exercise: Tree thinking ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1_Tree_thinking.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 2 + exercise: Data ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2_Data.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-11:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 3 + exercise: Basic methods ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3_Basic_methods.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00am-1:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 4 + exercise: Models and support ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4_Models_and_support.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 5 + exercise: Gene trees ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_5_Gene_trees.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:00am-3:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 6 + exercise: Molecular dating ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_6_MolecularDating.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([https://github.com/leholman/25.DTUmetabarcodingExercise/blob/main/README.md Metabarcoding Exercises]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test.pdf Test])([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test_Answers.pdf Answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Postprocess_exercise&amp;diff=610</id>
		<title>Postprocess exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Postprocess_exercise&amp;diff=610"/>
		<updated>2026-01-13T16:50:56Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise, you will perform essential post-alignment processing on BAM files to prepare them for reliable variant calling. Raw aligned BAM files often contain artifacts that can lead to false variants if not handled correctly. Today you will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Mark duplicate reads in BAM files&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Examine the effect of duplicate marking on read interpretation&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Merge multiple sequencing libraries from the same individual into a single BAM file&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;postalign&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Enter the &amp;lt;code&amp;gt;postalign&amp;lt;/code&amp;gt; directory&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Duplicate Marking&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will work with data from a Han Chinese individual (HG00418), sequenced to approximately 40× coverage using Illumina paired-end sequencing. For speed, we only use reads mapping to chromosome 20 and only two sequencing libraries.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Library 1 BAM file:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/dupremoval/ERR016028_chr20_sort.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The file is already trimmed, aligned, and sorted.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will mark duplicate reads using &amp;lt;b&amp;gt;Picard MarkDuplicates&amp;lt;/b&amp;gt;. The general command is:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
java -jar /home/ctools/picard_2.23.8/picard.jar MarkDuplicates \&lt;br /&gt;
    -I [input.bam] \&lt;br /&gt;
    -M [metrics.txt (this is part of the output, call it what you wish)] \&lt;br /&gt;
    -O [output.bam]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Suggested output name: &amp;lt;code&amp;gt;ERR016028_chr20_sort_markdup.bam&amp;lt;/code&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1:&amp;lt;/b&amp;gt; After running Picard, how many reads were marked as duplicates?  &lt;br /&gt;
(Hint: this number is printed in the Picard metrics output file.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Inspecting the Effect of Duplicate Marking&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To view reads in a specific genomic region, use:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view [input.sorted.bam] [chrom]:[start]-[end]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The BAM file must be indexed. Picard preserves sorting, so you do not need to re-sort it.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Inspect reads in the following region for both the &amp;lt;b&amp;gt;original file&amp;lt;/b&amp;gt; and your &amp;lt;b&amp;gt;duplicate-marked file&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:45996339-45996839&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Identify the two reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;ERR016028.5947720&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;ERR016028.18808080&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2:&amp;lt;/b&amp;gt; Why did MarkDuplicates consider these reads to be duplicates?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3:&amp;lt;/b&amp;gt; Which of the two reads was marked as a duplicate, and how can you tell from the SAM flag or tags?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Merging BAM Files&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Often, multiple sequencing libraries (or sequencing runs) exist for the same biological sample. Before variant calling, these must be merged into a single BAM file.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You will merge:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Your duplicate-marked file&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;The second library file:&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/dupremoval/ERR016025_chr20_sort_markdup.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;and find the command capable of merging multiple BAM files while preserving read groups and writing an index automatically. The command should keep the file sorted and generate the &amp;lt;code&amp;gt;.bai&amp;lt;/code&amp;gt; index in the same step.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4:&amp;lt;/b&amp;gt; Which &amp;lt;code&amp;gt;samtools&amp;lt;/code&amp;gt; command performs merging, with options to keep read groups and write the index?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the options:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
-c   --write-index&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Your merged BAM file should be named:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
HG00418_chr20_sort_markdup.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Inspect your merged file using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view HG00418_chr20_sort_markdup.bam | less -S&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5:&amp;lt;/b&amp;gt; Which SAM/BAM field indicates the sample or library of origin for each read?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6:&amp;lt;/b&amp;gt; What is the term for pooling multiple samples together into a single sequencing run?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7:&amp;lt;/b&amp;gt; What is the computational step where we separate pooled reads back into individual samples?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can find the answers [[Postprocess_exercise_answers|here]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations—you have completed the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Postprocess_exercise&amp;diff=609</id>
		<title>Postprocess exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Postprocess_exercise&amp;diff=609"/>
		<updated>2026-01-13T16:50:20Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise, you will perform essential post-alignment processing on BAM files to prepare them for reliable variant calling. Raw aligned BAM files often contain artifacts that can lead to false variants if not handled correctly. Today you will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Mark duplicate reads in BAM files&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Examine the effect of duplicate marking on read interpretation&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Merge multiple sequencing libraries from the same individual into a single BAM file&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;postalign&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Enter the &amp;lt;code&amp;gt;postalign&amp;lt;/code&amp;gt; directory&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Duplicate Marking&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will work with data from a Han Chinese individual (HG00418), sequenced to approximately 40× coverage using Illumina paired-end sequencing. For speed, we only use reads mapping to chromosome 20 and only two sequencing libraries.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Library 1 BAM file:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/dupremoval/ERR016028_chr20_sort.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The file is already trimmed, aligned, and sorted.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will mark duplicate reads using &amp;lt;b&amp;gt;Picard MarkDuplicates&amp;lt;/b&amp;gt;. The general command is:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
java -jar /home/ctools/picard_2.23.8/picard.jar MarkDuplicates \&lt;br /&gt;
    -I [input.bam] \&lt;br /&gt;
    -M [metrics.txt (this is part of the output, call it what you wish)] \&lt;br /&gt;
    -O [output.bam]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Suggested output name: &amp;lt;code&amp;gt;ERR016028_chr20_sort_markdup.bam&amp;lt;/code&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1:&amp;lt;/b&amp;gt; After running Picard, how many reads were marked as duplicates?  &lt;br /&gt;
(Hint: this number is printed in the Picard metrics output file.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Inspecting the Effect of Duplicate Marking&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To view reads in a specific genomic region, use:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view [input.sorted.bam] [chrom]:[start]-[end]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The BAM file must be indexed. Picard preserves sorting, so you do not need to re-sort it.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Inspect reads in the following region for both the &amp;lt;b&amp;gt;original file&amp;lt;/b&amp;gt; and your &amp;lt;b&amp;gt;duplicate-marked file&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:45996339-45996839&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Identify the two reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;ERR016028.5947720&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;ERR016028.18808080&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2:&amp;lt;/b&amp;gt; Why did MarkDuplicates consider these reads to be duplicates?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3:&amp;lt;/b&amp;gt; Which of the two reads was marked as a duplicate, and how can you tell from the SAM flag or tags?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Merging BAM Files&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Often, multiple sequencing libraries (or sequencing runs) exist for the same biological sample. Before variant calling, these must be merged into a single BAM file.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You will merge:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Your duplicate-marked file&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;The second library file:&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/dupremoval/ERR016025_chr20_sort_markdup.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;and find the command capable of merging multiple BAM files while preserving read groups and writing an index automatically. The command should keep the file sorted and generate the &amp;lt;code&amp;gt;.bai&amp;lt;/code&amp;gt; index in the same step.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4:&amp;lt;/b&amp;gt; Which &amp;lt;code&amp;gt;samtools&amp;lt;/code&amp;gt; command performs merging, with options to keep read groups and write the index?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the options:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
-c   --write-index&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Your merged BAM file should be named:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
HG00418_chr20_sort_markdup.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Inspect your merged file using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view HG00418_chr20_sort_markdup.bam | less -S&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5:&amp;lt;/b&amp;gt; Which SAM/BAM field indicates the sample or library of origin for each read?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6:&amp;lt;/b&amp;gt; What is the term for pooling multiple samples together into a single sequencing run?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7:&amp;lt;/b&amp;gt; What is the computational step where we separate pooled reads back into individual samples?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can find the answers [[Postprocess_exercise_answers here]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations—you have completed the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=608</id>
		<title>Exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=608"/>
		<updated>2026-01-12T15:41:47Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Phylogenomics&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;David A. Duchene&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Marsupials are a group of mammals that are unique to Australasia and the Americas. Several major groups of marsupials first appeared between 50 and 70 million years ago, during events of fast diversification. Given these are ancient and fast events, resolving the relationships among early marsupials is difficult, and remains a matter of interest in mammalian biology.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Today&#039;s exercises focus on the most fundamental concepts in phylogenomics, with the aim of resolving longstanding questions of the evolution of Australasian marsupials.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s make sense of our current understanding of marsupial relationships by coding them in Newick format.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 1&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open R and load the required packages:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(ape,   lib.loc = &amp;quot;/home/ctools/Rlibs&amp;quot;)&lt;br /&gt;
library(strap, lib.loc = &amp;quot;/home/ctools/Rlibs&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
This is how you create a phylogenetic tree object in R from a Newick string:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;WRITE NEWICK HERE&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To write this tree, follow the verbal description of marsupial relationships in Newick format:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The Wallabies are sisters to the Kangaroos, and this broader grouping is sister to the Possums. Sister to all these is the grouping that contains the Koalas and the Wombats. Yet another, separate group of marsupials contains the carnivorous Numbats, whose sister is a group containing the Tasmanian Devil and the now-extinct Tasmanian Tiger. It is hypothesised that that the sister to these carnivorous marsupials is a group containing the Marsupial Mole, whose closer sister is a group containing the Bandicoots and the Bilby. Sister to all of the marsupials mentioned so far is the enigmatic American Monito del Monte, and sister yet to all of these are the American Opossums. Finally, the Platypus and the Echidna form a group that is sister to all other mammals.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make sure you add a semicolon (&amp;lt;code&amp;gt;;&amp;lt;/code&amp;gt;) at the end of your tree. Now attempt to rearrange the names around so that they are in order of the least diverse to the most, while maintaining the relationships intact.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Compare your tree with the student sitting next to you. Discuss whether the Newick trees are different. Then evaluate whether the relationships in your trees are the same, even if the exact written text string is different.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you get too many errors, then use:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;((Elephant,Armadillo),(((Squirrel,Rabbit),(Monkey,Treeshrew)),(Shrew,(Whale,(Bat,(Cat,Rhinoceros))))));&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now plot your tree into a PDF using two different representations:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;myTree.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(myTree, type = &amp;quot;phylogram&amp;quot;)&lt;br /&gt;
plot(myTree, type = &amp;quot;unrooted&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; Do the two trees in the file contain the same information?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2.&amp;lt;/b&amp;gt; Can you draw any information from the branch lengths in these trees?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3.&amp;lt;/b&amp;gt; What information about the timing of each of these divergence events is available in the first tree?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4.&amp;lt;/b&amp;gt; Which of the two trees might be the most appropriate in cases where you have little prior information about the data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 2&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Load two data alignments, and then open the basic information about them and visualize a small portion:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read data&lt;br /&gt;
unaligned_mars &amp;amp;lt;- read.FASTA(&amp;quot;/home/projects/22126_NGS/exercises/phylogenomics/marsupials_unaligned.fasta&amp;quot;)&lt;br /&gt;
aligned_mars &amp;amp;lt;- as.matrix(read.FASTA(&amp;quot;/home/projects/22126_NGS/exercises/phylogenomics/marsupials_aligned.fasta&amp;quot;))&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of unaligned data&lt;br /&gt;
###########################&lt;br /&gt;
unaligned_mars&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of aligned data&lt;br /&gt;
###########################&lt;br /&gt;
aligned_mars&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of unaligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(do.call(rbind, lapply(as.character(unaligned_mars), `[`, 1:10)))&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of aligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(as.character(aligned_mars)[1:11, 1:10])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5.&amp;lt;/b&amp;gt; What are the primary differences between these two alignments, and why is only one of them suitable for phylogenetic inference?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The following code will remove any alignment sites (columns) with missing data (aka gaps or indels). It then builds basic trees from the complete and filtered alignments using two methods (ordinary least squares, &amp;lt;code&amp;gt;ols&amp;lt;/code&amp;gt;, and balanced minimum evolution, &amp;lt;code&amp;gt;bme&amp;lt;/code&amp;gt;):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Filter out sites with missing data &lt;br /&gt;
filtered_mars &amp;amp;lt;- aligned_mars[, !colSums(as.character(aligned_mars) == &amp;quot;-&amp;quot;) &amp;amp;gt; 0]&lt;br /&gt;
&lt;br /&gt;
# Make matrices of pairwise distances between taxa&lt;br /&gt;
dists_full &amp;amp;lt;- dist.dna(aligned_mars, model = &amp;quot;K80&amp;quot;, pairwise.deletion = T)&lt;br /&gt;
dists_filt &amp;amp;lt;- dist.dna(filtered_mars, model = &amp;quot;K80&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Make trees for the two data sets, under two methods each&lt;br /&gt;
basicTrees &amp;amp;lt;- list()&lt;br /&gt;
basicTrees$full_ols &amp;amp;lt;- fastme.ols(dists_full)&lt;br /&gt;
basicTrees$full_bme &amp;amp;lt;- fastme.bal(dists_full)&lt;br /&gt;
basicTrees$filt_ols &amp;amp;lt;- fastme.ols(dists_filt)&lt;br /&gt;
basicTrees$filt_bme &amp;amp;lt;- fastme.bal(dists_filt)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6.&amp;lt;/b&amp;gt; Before looking at any of the trees, what do you think are the benefits and drawbacks of removing sites with missing data?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Try plotting a few of these trees with the approaches that you used in Exercise 1.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Next, we will look at the total lengths of these trees:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
lapply(basicTrees, function(x) sum(x$edge.length))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7.&amp;lt;/b&amp;gt; What do these tree lengths measure?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8.&amp;lt;/b&amp;gt; Why is there a difference between the filtered and unfiltered data sets?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Do not worry at this stage about the differences between the two methods, but if you have time discuss with your partner what the difference is and what it means for your interpretation of the data.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 3&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
From within R, let&#039;s run IQ-TREE 3 under two different substitution models, adding statistical supports for the branches (upcoming lecture):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Run maximum-likelihood with a very simple model&lt;br /&gt;
system(&amp;quot;/home/ctools/iqtree-3.0.1-Linux/bin/iqtree3 -s /home/projects/22126_NGS/exercises/phylogenomics/marsupials_aligned.fasta -m JC -bb 1000 -pre mars_jc&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Run maximum-likelihood with a more complex model&lt;br /&gt;
system(&amp;quot;/home/ctools/iqtree-3.0.1-Linux/bin/iqtree3 -s /home/projects/22126_NGS/exercises/phylogenomics/marsupials_aligned.fasta -m GTR+R6 -bb 1000 -pre mars_gtr&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s visualise the trees from the three different methods so far:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read maximum likelihood trees&lt;br /&gt;
mars_jc &amp;amp;lt;- read.tree(&amp;quot;mars_jc.treefile&amp;quot;)&lt;br /&gt;
mars_gtr &amp;amp;lt;- read.tree(&amp;quot;mars_gtr.treefile&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot all four inferred trees into a PDF&lt;br /&gt;
pdf(&amp;quot;marsupial_trees.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
par(mfrow = c(2, 2))&lt;br /&gt;
plot(basicTrees$full_ols, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Ordinary Least Squares&amp;quot;)&lt;br /&gt;
plot(basicTrees$full_bme, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Balanced Min Evolution&amp;quot;)&lt;br /&gt;
plot(mars_jc, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (JC)&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9.&amp;lt;/b&amp;gt; Do you think that these methods lead to substantially different results? Lay out a few reasons for your answer.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 4&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Using the runs from the previous exercise, let&#039;s open the &amp;lt;code&amp;gt;.iqtree&amp;lt;/code&amp;gt; files from each run (you can then exit by pressing &amp;lt;code&amp;gt;q&amp;lt;/code&amp;gt;) and examine some of the details of the analyses.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Output summary for the run with the simple model&lt;br /&gt;
system(&amp;quot;less mars_jc.iqtree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Output summary for the run with the more complex model&lt;br /&gt;
system(&amp;quot;less mars_gtr.iqtree&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10.&amp;lt;/b&amp;gt; Which of the two models has more parameters (more complexity) and which model has the best BIC score (i.e. the lowest), and what does this tell you about the two models?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11.&amp;lt;/b&amp;gt; Does one model infer the total tree length to be much greater than the other? Discuss the possible reason for this with the student beside you.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12.&amp;lt;/b&amp;gt; From the GTR run and “Rate Parameter R”, which pairs of nucleotides has the most common type of substitution, and does this tell you anything about the biochemistry of the molecules analysed?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q13.&amp;lt;/b&amp;gt; From the same run and the “Model of rate heterogeneity”, are there any portions of the data that evolve much faster than the rest? Note that, for example, a relative rate of 2 means a portion of the data is evolving twice as fast as the mean.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14.&amp;lt;/b&amp;gt; From the time stamps at the bottom of this file, did one model take much longer than the other, and what could this mean if you have a very large data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s examine the branch supports from one of these runs, using the tree that you loaded previously into R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;mars_branch_supports.pdf&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, use.edge.length = F)&lt;br /&gt;
nodelabels(mars_gtr$node.label, frame = &amp;quot;circle&amp;quot;, bg = &amp;quot;white&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q15.&amp;lt;/b&amp;gt; What does this tell you about our overall confidence in marsupial relationships from these data, and which are likely the most difficult relationships to resolve?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 5&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A previous set of analyses has led to the gene trees for several genomic regions. Read and briefly explore these data in R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_trs &amp;amp;lt;- read.tree(&amp;quot;/home/projects/22126_NGS/exercises/phylogenomics/marsupials.tree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot 9 randomly chosen trees from the set&lt;br /&gt;
pdf(&amp;quot;mars_example_gene_trees.pdf&amp;quot;, height = 15, width = 15)&lt;br /&gt;
par(mfrow = c(3, 3), mar = c(0.5, 0.5, 0.5, 0.5))&lt;br /&gt;
for(i in sample(1:length(mars_trs), 9)) plot(mars_trs[[i]], type = &amp;quot;unrooted&amp;quot;, cex = 1.5)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Examine the trees in the PDF and determine whether any of them have surprising relationships at deep branches.&lt;br /&gt;
Speculate on the possible causes of the discordance (hint: what could be the influence/relevance of the branch lengths?).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s use these trees and a fast consensus method of tree inference, and compare the tree with that from maximum likelihood.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_cons &amp;amp;lt;- consensus(mars_trs, p = 0.5)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;mars_main_trees.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
plot(mars_cons, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Majority-Rule Consensus&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q16.&amp;lt;/b&amp;gt; How would you qualify the signal in the gene trees regarding the early branching events in the marsupial tree, and what do you think were the biological processes that led to this signal?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 6&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Molecular dating is a difficult and advanced analysis. However, we can sometimes rely on fast methods for very large data sets or exploratory analysis. In the following, we root our tree of the marsupials and provide it to a fast dating method. We apply two calibrations: one for the root (65–90 Mya) and one for the split between Koalas and Wombats (2.5–5.5 Mya).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Root IQ-TREE inference&lt;br /&gt;
mars_tr &amp;amp;lt;- root(mars_gtr, &amp;quot;Opossum&amp;quot;, resolve.root = T)&lt;br /&gt;
&lt;br /&gt;
# Perform dating analysis&lt;br /&gt;
ctrl &amp;amp;lt;- chronos.control(dual.iter.max = 1000)&lt;br /&gt;
cal &amp;amp;lt;- data.frame(node = c(20, 12), age.min = c(2.5, 6.5), age.max = c(5.5, 9))&lt;br /&gt;
mars_dated &amp;amp;lt;- chronos(mars_tr, calibration = cal, control = ctrl)&lt;br /&gt;
mars_dated$edge.length &amp;amp;lt;- mars_dated$edge.length * 10&lt;br /&gt;
mars_dated$root.time &amp;amp;lt;- max(branching.times(mars_dated))&lt;br /&gt;
&lt;br /&gt;
# Plot dating analysis&lt;br /&gt;
pdf(&amp;quot;marsupials_dated.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
geoscalePhylo(&lt;br /&gt;
  mars_dated,&lt;br /&gt;
  units = c(&amp;quot;Period&amp;quot;, &amp;quot;Epoch&amp;quot;),&lt;br /&gt;
  boxes = &amp;quot;Epoch&amp;quot;,&lt;br /&gt;
  width = 3,&lt;br /&gt;
  cex.age = 1.5,&lt;br /&gt;
  cex.ts = 1.5,&lt;br /&gt;
  cex.tip = 1.5&lt;br /&gt;
)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q17.&amp;lt;/b&amp;gt; What do these date inferences suggest about the diversification of marsupials with relation to the Cretaceous/Palaeogene mass extinction event, or other major geological transitions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q18.&amp;lt;/b&amp;gt; What forms of uncertainty are missing in this dated tree figure, and how would you consider incorporating them?&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=595</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=595"/>
		<updated>2026-01-12T09:14:14Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; The same exercise page will be used throughout the day: ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 1 + exercise: Tree thinking ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1_Tree_thinking.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 2 + exercise: Data ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2_Data.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-11:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 3 + exercise: Basic methods ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3_Basic_methods.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00am-1:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 4 + exercise: Models and support ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4_Models_and_support.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 5 + exercise: Gene trees ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_5_Gene_trees.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:00am-3:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 6 + exercise: Molecular dating ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_6_MolecularDating.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([https://github.com/leholman/25.DTUmetabarcodingExercise/blob/main/README.md Metabarcoding Exercises]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test.pdf Test])([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test_Answers.pdf Answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=594</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=594"/>
		<updated>2026-01-12T08:44:33Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: ([[ Microbial_genomics_exercise ]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; The same exercise page will be used throughout the day: ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 1 + exercise: Tree thinking ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1_Tree_thinking.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 2 + exercise: Data ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2_Data.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-11:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 3 + exercise: Basic methods ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3_Basic_methods.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00am-1:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 4 + exercise: Models and support ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4_Models_and_support.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 5 + exercise: Gene trees ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_5_Gene_trees.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:00am-3:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture 6 + exercise: Molecular dating ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_6_MolecularDating.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Metabarcoding Exercise]]) ([[Metabarcoding Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test.pdf Test])([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test_Answers.pdf Answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=532</id>
		<title>Exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=532"/>
		<updated>2026-01-11T07:50:14Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Phylogenomics&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;David A. Duchene&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Marsupials are a group of mammals that are unique to Australasia and the Americas. Several major groups of marsupials first appeared between 50 and 70 million years ago, during events of fast diversification. Given these are ancient and fast events, resolving the relationships among early marsupials is difficult, and remains a matter of interest in mammalian biology.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Today&#039;s exercises focus on the most fundamental concepts in phylogenomics, with the aim of resolving longstanding questions of the evolution of Australasian marsupials.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s make sense of our current understanding of marsupial relationships by coding them in Newick format.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 1&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open R and load the required packages:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(ape,   lib.loc = &amp;quot;/home/ctools/Rlibs&amp;quot;)&lt;br /&gt;
library(strap, lib.loc = &amp;quot;/home/ctools/Rlibs&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create an object containing a Newick tree:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;WRITE NEWICK HERE&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To write this tree, follow the verbal description of marsupial relationships in Newick format:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The Wallabies are sisters to the Kangaroos, and this broader grouping is sister to the Possums. Sister to all these is the grouping that contains the Koalas and the Wombats. Yet another, separate group of marsupials contains the carnivorous Numbats, whose sister is a group containing the Tasmanian Devil and the now-extinct Tasmanian Tiger. It is hypothesised that that the sister to these carnivorous marsupials is a group containing the Marsupial Mole, whose closer sister is a group containing the Bandicoots and the Bilby. Sister to all of the marsupials mentioned so far is the enigmatic American Monito del Monte, and sister yet to all of these are the American Opossums. Finally, the Platypus and the Echidna form a group that is sister to all other mammals.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make sure you add a semicolon (&amp;lt;code&amp;gt;;&amp;lt;/code&amp;gt;) at the end of your tree. Now attempt to rearrange the names around so that they are in order of the least diverse to the most, while maintaining the relationships intact.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Compare your tree with the student sitting next to you. Discuss whether the Newick trees are different. Then evaluate whether the relationships in your trees are the same, even if the exact written text string is different.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you get too many errors, then use:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;((Elephant,Armadillo),(((Squirrel,Rabbit),(Monkey,Treeshrew)),(Shrew,(Whale,(Bat,(Cat,Rhinoceros))))));&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now plot your tree into a PDF using two different representations:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;myTree.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(myTree, type = &amp;quot;phylogram&amp;quot;)&lt;br /&gt;
plot(myTree, type = &amp;quot;unrooted&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; Do the two trees in the file contain the same information?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2.&amp;lt;/b&amp;gt; Can you draw any information from the branch lengths in these trees?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3.&amp;lt;/b&amp;gt; What information about the timing of each of these divergence events is available in the first tree?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4.&amp;lt;/b&amp;gt; Which of the two trees might be the most appropriate in cases where you have little prior information about the data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 2&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Load two data alignments, and then open the basic information about them and visualize a small portion:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read data&lt;br /&gt;
unaligned_mars &amp;amp;lt;- read.FASTA(&amp;quot;/home/projects/22126_NGS/exercises/phylogenomics/marsupials_unaligned.fasta&amp;quot;)&lt;br /&gt;
aligned_mars &amp;amp;lt;- as.matrix(read.FASTA(&amp;quot;/home/projects/22126_NGS/exercises/phylogenomics/marsupials_aligned.fasta&amp;quot;))&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of unaligned data&lt;br /&gt;
###########################&lt;br /&gt;
unaligned_mars&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of aligned data&lt;br /&gt;
###########################&lt;br /&gt;
aligned_mars&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of unaligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(do.call(rbind, lapply(as.character(unaligned_mars), `[`, 1:10)))&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of aligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(as.character(aligned_mars)[1:11, 1:10])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5.&amp;lt;/b&amp;gt; What are the primary differences between these two alignments, and why is only one of them suitable for phylogenetic inference?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The following code will remove any alignment sites (columns) with missing data (aka gaps or indels). It then builds basic trees from the complete and filtered alignments using two methods (ordinary least squares, &amp;lt;code&amp;gt;ols&amp;lt;/code&amp;gt;, and balanced minimum evolution, &amp;lt;code&amp;gt;bme&amp;lt;/code&amp;gt;):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Filter out sites with missing data &lt;br /&gt;
filtered_mars &amp;amp;lt;- aligned_mars[, !colSums(as.character(aligned_mars) == &amp;quot;-&amp;quot;) &amp;amp;gt; 0]&lt;br /&gt;
&lt;br /&gt;
# Make matrices of pairwise distances between taxa&lt;br /&gt;
dists_full &amp;amp;lt;- dist.dna(aligned_mars, model = &amp;quot;K80&amp;quot;, pairwise.deletion = T)&lt;br /&gt;
dists_filt &amp;amp;lt;- dist.dna(filtered_mars, model = &amp;quot;K80&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Make trees for the two data sets, under two methods each&lt;br /&gt;
basicTrees &amp;amp;lt;- list()&lt;br /&gt;
basicTrees$full_ols &amp;amp;lt;- fastme.ols(dists_full)&lt;br /&gt;
basicTrees$full_bme &amp;amp;lt;- fastme.bal(dists_full)&lt;br /&gt;
basicTrees$filt_ols &amp;amp;lt;- fastme.ols(dists_filt)&lt;br /&gt;
basicTrees$filt_bme &amp;amp;lt;- fastme.bal(dists_filt)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6.&amp;lt;/b&amp;gt; Before looking at any of the trees, what do you think are the benefits and drawbacks of removing sites with missing data?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Try plotting a few of these trees with the approaches that you used in Exercise 1.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Next, we will look at the total lengths of these trees:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
lapply(basicTrees, function(x) sum(x$edge.length))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7.&amp;lt;/b&amp;gt; What do these tree lengths measure?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8.&amp;lt;/b&amp;gt; Why is there a difference between the filtered and unfiltered data sets?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Do not worry at this stage about the differences between the two methods, but if you have time discuss with your partner what the difference is and what it means for your interpretation of the data.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 3&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
From within R, let&#039;s run IQ-TREE 3 under two different substitution models, adding statistical supports for the branches (upcoming lecture):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Run maximum-likelihood with a very simple model&lt;br /&gt;
system(&amp;quot;/home/ctools/iqtree-3.0.1-Linux/bin/iqtree3 -s /home/projects/22126_NGS/exercises/phylogenomics/marsupials_aligned.fasta -m JC -bb 1000 -pre mars_jc&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Run maximum-likelihood with a more complex model&lt;br /&gt;
system(&amp;quot;/home/ctools/iqtree-3.0.1-Linux/bin/iqtree3 -s /home/projects/22126_NGS/exercises/phylogenomics/marsupials_aligned.fasta -m GTR+R6 -bb 1000 -pre mars_gtr&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s visualise the trees from the three different methods so far:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read maximum likelihood trees&lt;br /&gt;
mars_jc &amp;amp;lt;- read.tree(&amp;quot;mars_jc.treefile&amp;quot;)&lt;br /&gt;
mars_gtr &amp;amp;lt;- read.tree(&amp;quot;mars_gtr.treefile&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot all four inferred trees into a PDF&lt;br /&gt;
pdf(&amp;quot;marsupial_trees.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
par(mfrow = c(2, 2))&lt;br /&gt;
plot(basicTrees$full_ols, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Ordinary Least Squares&amp;quot;)&lt;br /&gt;
plot(basicTrees$full_bme, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Balanced Min Evolution&amp;quot;)&lt;br /&gt;
plot(mars_jc, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (JC)&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9.&amp;lt;/b&amp;gt; Do you think that these methods lead to substantially different results? Lay out a few reasons for your answer.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 4&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Using the runs from the previous exercise, let&#039;s open the &amp;lt;code&amp;gt;.iqtree&amp;lt;/code&amp;gt; files from each run (you can then exit by pressing &amp;lt;code&amp;gt;q&amp;lt;/code&amp;gt;) and examine some of the details of the analyses.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Output summary for the run with the simple model&lt;br /&gt;
system(&amp;quot;less mars_jc.iqtree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Output summary for the run with the more complex model&lt;br /&gt;
system(&amp;quot;less mars_gtr.iqtree&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10.&amp;lt;/b&amp;gt; Which of the two models has more parameters (more complexity) and which model has the best BIC score (i.e. the lowest), and what does this tell you about the two models?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11.&amp;lt;/b&amp;gt; Does one model infer the total tree length to be much greater than the other? Discuss the possible reason for this with the student beside you.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12.&amp;lt;/b&amp;gt; From the GTR run and “Rate Parameter R”, which pairs of nucleotides has the most common type of substitution, and does this tell you anything about the biochemistry of the molecules analysed?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q13.&amp;lt;/b&amp;gt; From the same run and the “Model of rate heterogeneity”, are there any portions of the data that evolve much faster than the rest? Note that, for example, a relative rate of 2 means a portion of the data is evolving twice as fast as the mean.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14.&amp;lt;/b&amp;gt; From the time stamps at the bottom of this file, did one model take much longer than the other, and what could this mean if you have a very large data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s examine the branch supports from one of these runs, using the tree that you loaded previously into R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;mars_branch_supports.pdf&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, use.edge.length = F)&lt;br /&gt;
nodelabels(mars_gtr$node.label, frame = &amp;quot;circle&amp;quot;, bg = &amp;quot;white&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q15.&amp;lt;/b&amp;gt; What does this tell you about our overall confidence in marsupial relationships from these data, and which are likely the most difficult relationships to resolve?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 5&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A previous set of analyses has led to the gene trees for several genomic regions. Read and briefly explore these data in R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_trs &amp;amp;lt;- read.tree(&amp;quot;/home/projects/22126_NGS/exercises/phylogenomics/marsupials.tree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot 9 randomly chosen trees from the set&lt;br /&gt;
pdf(&amp;quot;mars_example_gene_trees.pdf&amp;quot;, height = 15, width = 15)&lt;br /&gt;
par(mfrow = c(3, 3), mar = c(0.5, 0.5, 0.5, 0.5))&lt;br /&gt;
for(i in sample(1:length(mars_trs), 9)) plot(mars_trs[[i]], type = &amp;quot;unrooted&amp;quot;, cex = 1.5)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Examine the trees in the PDF and determine whether any of them have surprising relationships at deep branches.&lt;br /&gt;
Speculate on the possible causes of the discordance (hint: what could be the influence/relevance of the branch lengths?).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s use these trees and a fast consensus method of tree inference, and compare the tree with that from maximum likelihood.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_cons &amp;amp;lt;- consensus(mars_trs, p = 0.5)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;mars_main_trees.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
plot(mars_cons, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Majority-Rule Consensus&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q16.&amp;lt;/b&amp;gt; How would you qualify the signal in the gene trees regarding the early branching events in the marsupial tree, and what do you think were the biological processes that led to this signal?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 6&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Molecular dating is a difficult and advanced analysis. However, we can sometimes rely on fast methods for very large data sets or exploratory analysis. In the following, we root our tree of the marsupials and provide it to a fast dating method. We apply two calibrations: one for the root (65–90 Mya) and one for the split between Koalas and Wombats (2.5–5.5 Mya).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Root IQ-TREE inference&lt;br /&gt;
mars_tr &amp;amp;lt;- root(mars_gtr, &amp;quot;Opossum&amp;quot;, resolve.root = T)&lt;br /&gt;
&lt;br /&gt;
# Perform dating analysis&lt;br /&gt;
ctrl &amp;amp;lt;- chronos.control(dual.iter.max = 1000)&lt;br /&gt;
cal &amp;amp;lt;- data.frame(node = c(20, 12), age.min = c(2.5, 6.5), age.max = c(5.5, 9))&lt;br /&gt;
mars_dated &amp;amp;lt;- chronos(mars_tr, calibration = cal, control = ctrl)&lt;br /&gt;
mars_dated$edge.length &amp;amp;lt;- mars_dated$edge.length * 10&lt;br /&gt;
mars_dated$root.time &amp;amp;lt;- max(branching.times(mars_dated))&lt;br /&gt;
&lt;br /&gt;
# Plot dating analysis&lt;br /&gt;
pdf(&amp;quot;marsupials_dated.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
geoscalePhylo(&lt;br /&gt;
  mars_dated,&lt;br /&gt;
  units = c(&amp;quot;Period&amp;quot;, &amp;quot;Epoch&amp;quot;),&lt;br /&gt;
  boxes = &amp;quot;Epoch&amp;quot;,&lt;br /&gt;
  width = 3,&lt;br /&gt;
  cex.age = 1.5,&lt;br /&gt;
  cex.ts = 1.5,&lt;br /&gt;
  cex.tip = 1.5&lt;br /&gt;
)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q17.&amp;lt;/b&amp;gt; What do these date inferences suggest about the diversification of marsupials with relation to the Cretaceous/Palaeogene mass extinction event, or other major geological transitions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q18.&amp;lt;/b&amp;gt; What forms of uncertainty are missing in this dated tree figure, and how would you consider incorporating them?&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=531</id>
		<title>Exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=531"/>
		<updated>2026-01-11T07:47:45Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Phylogenomics&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;David A. Duchene&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Marsupials are a group of mammals that are unique to Australasia and the Americas. Several major groups of marsupials first appeared between 50 and 70 million years ago, during events of fast diversification. Given these are ancient and fast events, resolving the relationships among early marsupials is difficult, and remains a matter of interest in mammalian biology.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Today&#039;s exercises focus on the most fundamental concepts in phylogenomics, with the aim of resolving longstanding questions of the evolution of Australasian marsupials.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s make sense of our current understanding of marsupial relationships by coding them in Newick format.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 1&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open R and load the required packages:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(ape,   lib.loc = &amp;quot;/home/ctools/Rlibs&amp;quot;)&lt;br /&gt;
library(strap, lib.loc = &amp;quot;/home/ctools/Rlibs&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create an object containing a Newick tree:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;WRITE NEWICK HERE&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To write this tree, follow the verbal description of marsupial relationships in Newick format:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The Wallabies are sisters to the Kangaroos, and this broader grouping is sister to the Possums. Sister to all these is the grouping that contains the Koalas and the Wombats. Yet another, separate group of marsupials contains the carnivorous Numbats, whose sister is a group containing the Tasmanian Devil and the now-extinct Tasmanian Tiger. It is hypothesised that that the sister to these carnivorous marsupials is a group containing the Marsupial Mole, whose closer sister is a group containing the Bandicoots and the Bilby. Sister to all of the marsupials mentioned so far is the enigmatic American Monito del Monte, and sister yet to all of these are the American Opossums. Finally, the Platypus and the Echidna form a group that is sister to all other mammals.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make sure you add a semicolon (&amp;lt;code&amp;gt;;&amp;lt;/code&amp;gt;) at the end of your tree. Now attempt to rearrange the names around so that they are in order of the least diverse to the most, while maintaining the relationships intact.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Compare your tree with the student sitting next to you. Discuss whether the Newick trees are different. Then evaluate whether the relationships in your trees are the same, even if the exact written text string is different.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you get too many errors, then use:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;((Elephant,Armadillo),(((Squirrel,Rabbit),(Monkey,Treeshrew)),(Shrew,(Whale,(Bat,(Cat,Rhinoceros))))));&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now plot your tree into a PDF using two different representations:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;myTree.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(myTree, type = &amp;quot;phylogram&amp;quot;)&lt;br /&gt;
plot(myTree, type = &amp;quot;unrooted&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; Do the two trees in the file contain the same information?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2.&amp;lt;/b&amp;gt; Can you draw any information from the branch lengths in these trees?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3.&amp;lt;/b&amp;gt; What information about the timing of each of these divergence events is available in the first tree?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4.&amp;lt;/b&amp;gt; Which of the two trees might be the most appropriate in cases where you have little prior information about the data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 2&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Load two data alignments, and then open the basic information about them and visualize a small portion:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read data&lt;br /&gt;
unaligned_mars &amp;amp;lt;- read.FASTA(&amp;quot;marsupials_unaligned.fasta&amp;quot;)&lt;br /&gt;
aligned_mars &amp;amp;lt;- as.matrix(read.FASTA(&amp;quot;marsupials_aligned.fasta&amp;quot;))&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of unaligned data&lt;br /&gt;
###########################&lt;br /&gt;
unaligned_mars&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of aligned data&lt;br /&gt;
###########################&lt;br /&gt;
aligned_mars&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of unaligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(do.call(rbind, lapply(as.character(unaligned_mars), `[`, 1:10)))&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of aligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(as.character(aligned_mars)[1:11, 1:10])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5.&amp;lt;/b&amp;gt; What are the primary differences between these two alignments, and why is only one of them suitable for phylogenetic inference?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The following code will remove any alignment sites (columns) with missing data (aka gaps or indels). It then builds basic trees from the complete and filtered alignments using two methods (ordinary least squares, &amp;lt;code&amp;gt;ols&amp;lt;/code&amp;gt;, and balanced minimum evolution, &amp;lt;code&amp;gt;bme&amp;lt;/code&amp;gt;):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Filter out sites with missing data &lt;br /&gt;
filtered_mars &amp;amp;lt;- aligned_mars[, !colSums(as.character(aligned_mars) == &amp;quot;-&amp;quot;) &amp;amp;gt; 0]&lt;br /&gt;
&lt;br /&gt;
# Make matrices of pairwise distances between taxa&lt;br /&gt;
dists_full &amp;amp;lt;- dist.dna(aligned_mars, model = &amp;quot;K80&amp;quot;, pairwise.deletion = T)&lt;br /&gt;
dists_filt &amp;amp;lt;- dist.dna(filtered_mars, model = &amp;quot;K80&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Make trees for the two data sets, under two methods each&lt;br /&gt;
basicTrees &amp;amp;lt;- list()&lt;br /&gt;
basicTrees$full_ols &amp;amp;lt;- fastme.ols(dists_full)&lt;br /&gt;
basicTrees$full_bme &amp;amp;lt;- fastme.bal(dists_full)&lt;br /&gt;
basicTrees$filt_ols &amp;amp;lt;- fastme.ols(dists_filt)&lt;br /&gt;
basicTrees$filt_bme &amp;amp;lt;- fastme.bal(dists_filt)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6.&amp;lt;/b&amp;gt; Before looking at any of the trees, what do you think are the benefits and drawbacks of removing sites with missing data?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Try plotting a few of these trees with the approaches that you used in Exercise 1.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Next, we will look at the total lengths of these trees:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
lapply(basicTrees, function(x) sum(x$edge.length))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7.&amp;lt;/b&amp;gt; What do these tree lengths measure?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8.&amp;lt;/b&amp;gt; Why is there a difference between the filtered and unfiltered data sets?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Do not worry at this stage about the differences between the two methods, but if you have time discuss with your partner what the difference is and what it means for your interpretation of the data.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 3&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
From within R, let&#039;s run IQ-TREE 3 under two different substitution models, adding statistical supports for the branches (upcoming lecture):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Run maximum-likelihood with a very simple model&lt;br /&gt;
system(&amp;quot;/home/ctools/iqtree-3.0.1-Linux/bin/iqtree3 -s marsupials_aligned.fasta -m JC -bb 1000 -pre mars_jc&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Run maximum-likelihood with a more complex model&lt;br /&gt;
system(&amp;quot;/home/ctools/iqtree-3.0.1-Linux/bin/iqtree3 -s marsupials_aligned.fasta -m GTR+R6 -bb 1000 -pre mars_gtr&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s visualise the trees from the three different methods so far:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read maximum likelihood trees&lt;br /&gt;
mars_jc &amp;amp;lt;- read.tree(&amp;quot;mars_jc.treefile&amp;quot;)&lt;br /&gt;
mars_gtr &amp;amp;lt;- read.tree(&amp;quot;mars_gtr.treefile&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot all four inferred trees into a PDF&lt;br /&gt;
pdf(&amp;quot;marsupial_trees.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
par(mfrow = c(2, 2))&lt;br /&gt;
plot(basicTrees$full_ols, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Ordinary Least Squares&amp;quot;)&lt;br /&gt;
plot(basicTrees$full_bme, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Balanced Min Evolution&amp;quot;)&lt;br /&gt;
plot(mars_jc, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (JC)&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9.&amp;lt;/b&amp;gt; Do you think that these methods lead to substantially different results? Lay out a few reasons for your answer.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 4&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Using the runs from the previous exercise, let&#039;s open the &amp;lt;code&amp;gt;.iqtree&amp;lt;/code&amp;gt; files from each run (you can then exit by pressing &amp;lt;code&amp;gt;q&amp;lt;/code&amp;gt;) and examine some of the details of the analyses.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Output summary for the run with the simple model&lt;br /&gt;
system(&amp;quot;less mars_jc.iqtree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Output summary for the run with the more complex model&lt;br /&gt;
system(&amp;quot;less mars_gtr.iqtree&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10.&amp;lt;/b&amp;gt; Which of the two models has more parameters (more complexity) and which model has the best BIC score (i.e. the lowest), and what does this tell you about the two models?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11.&amp;lt;/b&amp;gt; Does one model infer the total tree length to be much greater than the other? Discuss the possible reason for this with the student beside you.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12.&amp;lt;/b&amp;gt; From the GTR run and “Rate Parameter R”, which pairs of nucleotides has the most common type of substitution, and does this tell you anything about the biochemistry of the molecules analysed?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q13.&amp;lt;/b&amp;gt; From the same run and the “Model of rate heterogeneity”, are there any portions of the data that evolve much faster than the rest? Note that, for example, a relative rate of 2 means a portion of the data is evolving twice as fast as the mean.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14.&amp;lt;/b&amp;gt; From the time stamps at the bottom of this file, did one model take much longer than the other, and what could this mean if you have a very large data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s examine the branch supports from one of these runs, using the tree that you loaded previously into R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;mars_branch_supports.pdf&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, use.edge.length = F)&lt;br /&gt;
nodelabels(mars_gtr$node.label, frame = &amp;quot;circle&amp;quot;, bg = &amp;quot;white&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q15.&amp;lt;/b&amp;gt; What does this tell you about our overall confidence in marsupial relationships from these data, and which are likely the most difficult relationships to resolve?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 5&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A previous set of analyses has led to the gene trees for several genomic regions. Read and briefly explore these data in R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_trs &amp;amp;lt;- read.tree(&amp;quot;marsupials.tree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot 9 randomly chosen trees from the set&lt;br /&gt;
pdf(&amp;quot;mars_example_gene_trees.pdf&amp;quot;, height = 15, width = 15)&lt;br /&gt;
par(mfrow = c(3, 3), mar = c(0.5, 0.5, 0.5, 0.5))&lt;br /&gt;
for(i in sample(1:length(mars_trs), 9)) plot(mars_trs[[i]], type = &amp;quot;unrooted&amp;quot;, cex = 1.5)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Examine the trees in the PDF and determine whether any of them have surprising relationships at deep branches.&lt;br /&gt;
Speculate on the possible causes of the discordance (hint: what could be the influence/relevance of the branch lengths?).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s use these trees and a fast consensus method of tree inference, and compare the tree with that from maximum likelihood.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_cons &amp;amp;lt;- consensus(mars_trs, p = 0.5)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;mars_main_trees.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
plot(mars_cons, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Majority-Rule Consensus&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q16.&amp;lt;/b&amp;gt; How would you qualify the signal in the gene trees regarding the early branching events in the marsupial tree, and what do you think were the biological processes that led to this signal?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 6&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Molecular dating is a difficult and advanced analysis. However, we can sometimes rely on fast methods for very large data sets or exploratory analysis. In the following, we root our tree of the marsupials and provide it to a fast dating method. We apply two calibrations: one for the root (65–90 Mya) and one for the split between Koalas and Wombats (2.5–5.5 Mya).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Root IQ-TREE inference&lt;br /&gt;
mars_tr &amp;amp;lt;- root(mars_gtr, &amp;quot;Opossum&amp;quot;, resolve.root = T)&lt;br /&gt;
&lt;br /&gt;
# Perform dating analysis&lt;br /&gt;
ctrl &amp;amp;lt;- chronos.control(dual.iter.max = 1000)&lt;br /&gt;
cal &amp;amp;lt;- data.frame(node = c(20, 12), age.min = c(2.5, 6.5), age.max = c(5.5, 9))&lt;br /&gt;
mars_dated &amp;amp;lt;- chronos(mars_tr, calibration = cal, control = ctrl)&lt;br /&gt;
mars_dated$edge.length &amp;amp;lt;- mars_dated$edge.length * 10&lt;br /&gt;
mars_dated$root.time &amp;amp;lt;- max(branching.times(mars_dated))&lt;br /&gt;
&lt;br /&gt;
# Plot dating analysis&lt;br /&gt;
pdf(&amp;quot;marsupials_dated.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
geoscalePhylo(&lt;br /&gt;
  mars_dated,&lt;br /&gt;
  units = c(&amp;quot;Period&amp;quot;, &amp;quot;Epoch&amp;quot;),&lt;br /&gt;
  boxes = &amp;quot;Epoch&amp;quot;,&lt;br /&gt;
  width = 3,&lt;br /&gt;
  cex.age = 1.5,&lt;br /&gt;
  cex.ts = 1.5,&lt;br /&gt;
  cex.tip = 1.5&lt;br /&gt;
)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q17.&amp;lt;/b&amp;gt; What do these date inferences suggest about the diversification of marsupials with relation to the Cretaceous/Palaeogene mass extinction event, or other major geological transitions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q18.&amp;lt;/b&amp;gt; What forms of uncertainty are missing in this dated tree figure, and how would you consider incorporating them?&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=530</id>
		<title>Exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=530"/>
		<updated>2026-01-11T07:43:39Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Phylogenomics&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;David A. Duchene&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Marsupials are a group of mammals that are unique to Australasia and the Americas. Several major groups of marsupials first appeared between 50 and 70 million years ago, during events of fast diversification. Given these are ancient and fast events, resolving the relationships among early marsupials is difficult, and remains a matter of interest in mammalian biology.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Today&#039;s exercises focus on the most fundamental concepts in phylogenomics, with the aim of resolving longstanding questions of the evolution of Australasian marsupials.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s make sense of our current understanding of marsupial relationships by coding them in Newick format.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 1&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open R and load the required packages:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(ape)&lt;br /&gt;
library(strap)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create an object containing a Newick tree:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;WRITE NEWICK HERE&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To write this tree, follow the verbal description of marsupial relationships in Newick format:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The Wallabies are sisters to the Kangaroos, and this broader grouping is sister to the Possums. Sister to all these is the grouping that contains the Koalas and the Wombats. Yet another, separate group of marsupials contains the carnivorous Numbats, whose sister is a group containing the Tasmanian Devil and the now-extinct Tasmanian Tiger. It is hypothesised that that the sister to these carnivorous marsupials is a group containing the Marsupial Mole, whose closer sister is a group containing the Bandicoots and the Bilby. Sister to all of the marsupials mentioned so far is the enigmatic American Monito del Monte, and sister yet to all of these are the American Opossums. Finally, the Platypus and the Echidna form a group that is sister to all other mammals.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make sure you add a semicolon (&amp;lt;code&amp;gt;;&amp;lt;/code&amp;gt;) at the end of your tree. Now attempt to rearrange the names around so that they are in order of the least diverse to the most, while maintaining the relationships intact.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Compare your tree with the student sitting next to you. Discuss whether the Newick trees are different. Then evaluate whether the relationships in your trees are the same, even if the exact written text string is different.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you get too many errors, then use:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;((Elephant,Armadillo),(((Squirrel,Rabbit),(Monkey,Treeshrew)),(Shrew,(Whale,(Bat,(Cat,Rhinoceros))))));&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now plot your tree into a PDF using two different representations:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;myTree.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(myTree, type = &amp;quot;phylogram&amp;quot;)&lt;br /&gt;
plot(myTree, type = &amp;quot;unrooted&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; Do the two trees in the file contain the same information?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2.&amp;lt;/b&amp;gt; Can you draw any information from the branch lengths in these trees?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3.&amp;lt;/b&amp;gt; What information about the timing of each of these divergence events is available in the first tree?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4.&amp;lt;/b&amp;gt; Which of the two trees might be the most appropriate in cases where you have little prior information about the data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 2&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Load two data alignments, and then open the basic information about them and visualize a small portion:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read data&lt;br /&gt;
unaligned_mars &amp;amp;lt;- read.FASTA(&amp;quot;marsupials_unaligned.fasta&amp;quot;)&lt;br /&gt;
aligned_mars &amp;amp;lt;- as.matrix(read.FASTA(&amp;quot;marsupials_aligned.fasta&amp;quot;))&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of unaligned data&lt;br /&gt;
###########################&lt;br /&gt;
unaligned_mars&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of aligned data&lt;br /&gt;
###########################&lt;br /&gt;
aligned_mars&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of unaligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(do.call(rbind, lapply(as.character(unaligned_mars), `[`, 1:10)))&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of aligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(as.character(aligned_mars)[1:11, 1:10])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5.&amp;lt;/b&amp;gt; What are the primary differences between these two alignments, and why is only one of them suitable for phylogenetic inference?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The following code will remove any alignment sites (columns) with missing data (aka gaps or indels). It then builds basic trees from the complete and filtered alignments using two methods (ordinary least squares, &amp;lt;code&amp;gt;ols&amp;lt;/code&amp;gt;, and balanced minimum evolution, &amp;lt;code&amp;gt;bme&amp;lt;/code&amp;gt;):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Filter out sites with missing data &lt;br /&gt;
filtered_mars &amp;amp;lt;- aligned_mars[, !colSums(as.character(aligned_mars) == &amp;quot;-&amp;quot;) &amp;amp;gt; 0]&lt;br /&gt;
&lt;br /&gt;
# Make matrices of pairwise distances between taxa&lt;br /&gt;
dists_full &amp;amp;lt;- dist.dna(aligned_mars, model = &amp;quot;K80&amp;quot;, pairwise.deletion = T)&lt;br /&gt;
dists_filt &amp;amp;lt;- dist.dna(filtered_mars, model = &amp;quot;K80&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Make trees for the two data sets, under two methods each&lt;br /&gt;
basicTrees &amp;amp;lt;- list()&lt;br /&gt;
basicTrees$full_ols &amp;amp;lt;- fastme.ols(dists_full)&lt;br /&gt;
basicTrees$full_bme &amp;amp;lt;- fastme.bal(dists_full)&lt;br /&gt;
basicTrees$filt_ols &amp;amp;lt;- fastme.ols(dists_filt)&lt;br /&gt;
basicTrees$filt_bme &amp;amp;lt;- fastme.bal(dists_filt)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6.&amp;lt;/b&amp;gt; Before looking at any of the trees, what do you think are the benefits and drawbacks of removing sites with missing data?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Try plotting a few of these trees with the approaches that you used in Exercise 1.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Next, we will look at the total lengths of these trees:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
lapply(basicTrees, function(x) sum(x$edge.length))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7.&amp;lt;/b&amp;gt; What do these tree lengths measure?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8.&amp;lt;/b&amp;gt; Why is there a difference between the filtered and unfiltered data sets?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Do not worry at this stage about the differences between the two methods, but if you have time discuss with your partner what the difference is and what it means for your interpretation of the data.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 3&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
From within R, let&#039;s run IQ-TREE 3 under two different substitution models, adding statistical supports for the branches (upcoming lecture):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Run maximum-likelihood with a very simple model&lt;br /&gt;
system(&amp;quot;/home/ctools/iqtree-3.0.1-Linux/bin/iqtree3 -s marsupials_aligned.fasta -m JC -bb 1000 -pre mars_jc&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Run maximum-likelihood with a more complex model&lt;br /&gt;
system(&amp;quot;/home/ctools/iqtree-3.0.1-Linux/bin/iqtree3 -s marsupials_aligned.fasta -m GTR+R6 -bb 1000 -pre mars_gtr&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s visualise the trees from the three different methods so far:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read maximum likelihood trees&lt;br /&gt;
mars_jc &amp;amp;lt;- read.tree(&amp;quot;mars_jc.treefile&amp;quot;)&lt;br /&gt;
mars_gtr &amp;amp;lt;- read.tree(&amp;quot;mars_gtr.treefile&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot all four inferred trees into a PDF&lt;br /&gt;
pdf(&amp;quot;marsupial_trees.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
par(mfrow = c(2, 2))&lt;br /&gt;
plot(basicTrees$full_ols, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Ordinary Least Squares&amp;quot;)&lt;br /&gt;
plot(basicTrees$full_bme, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Balanced Min Evolution&amp;quot;)&lt;br /&gt;
plot(mars_jc, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (JC)&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9.&amp;lt;/b&amp;gt; Do you think that these methods lead to substantially different results? Lay out a few reasons for your answer.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 4&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Using the runs from the previous exercise, let&#039;s open the &amp;lt;code&amp;gt;.iqtree&amp;lt;/code&amp;gt; files from each run (you can then exit by pressing &amp;lt;code&amp;gt;q&amp;lt;/code&amp;gt;) and examine some of the details of the analyses.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Output summary for the run with the simple model&lt;br /&gt;
system(&amp;quot;less mars_jc.iqtree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Output summary for the run with the more complex model&lt;br /&gt;
system(&amp;quot;less mars_gtr.iqtree&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10.&amp;lt;/b&amp;gt; Which of the two models has more parameters (more complexity) and which model has the best BIC score (i.e. the lowest), and what does this tell you about the two models?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11.&amp;lt;/b&amp;gt; Does one model infer the total tree length to be much greater than the other? Discuss the possible reason for this with the student beside you.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12.&amp;lt;/b&amp;gt; From the GTR run and “Rate Parameter R”, which pairs of nucleotides has the most common type of substitution, and does this tell you anything about the biochemistry of the molecules analysed?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q13.&amp;lt;/b&amp;gt; From the same run and the “Model of rate heterogeneity”, are there any portions of the data that evolve much faster than the rest? Note that, for example, a relative rate of 2 means a portion of the data is evolving twice as fast as the mean.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14.&amp;lt;/b&amp;gt; From the time stamps at the bottom of this file, did one model take much longer than the other, and what could this mean if you have a very large data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s examine the branch supports from one of these runs, using the tree that you loaded previously into R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;mars_branch_supports.pdf&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, use.edge.length = F)&lt;br /&gt;
nodelabels(mars_gtr$node.label, frame = &amp;quot;circle&amp;quot;, bg = &amp;quot;white&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q15.&amp;lt;/b&amp;gt; What does this tell you about our overall confidence in marsupial relationships from these data, and which are likely the most difficult relationships to resolve?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 5&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A previous set of analyses has led to the gene trees for several genomic regions. Read and briefly explore these data in R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_trs &amp;amp;lt;- read.tree(&amp;quot;marsupials.tree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot 9 randomly chosen trees from the set&lt;br /&gt;
pdf(&amp;quot;mars_example_gene_trees.pdf&amp;quot;, height = 15, width = 15)&lt;br /&gt;
par(mfrow = c(3, 3), mar = c(0.5, 0.5, 0.5, 0.5))&lt;br /&gt;
for(i in sample(1:length(mars_trs), 9)) plot(mars_trs[[i]], type = &amp;quot;unrooted&amp;quot;, cex = 1.5)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Examine the trees in the PDF and determine whether any of them have surprising relationships at deep branches.&lt;br /&gt;
Speculate on the possible causes of the discordance (hint: what could be the influence/relevance of the branch lengths?).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s use these trees and a fast consensus method of tree inference, and compare the tree with that from maximum likelihood.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_cons &amp;amp;lt;- consensus(mars_trs, p = 0.5)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;mars_main_trees.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
plot(mars_cons, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Majority-Rule Consensus&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q16.&amp;lt;/b&amp;gt; How would you qualify the signal in the gene trees regarding the early branching events in the marsupial tree, and what do you think were the biological processes that led to this signal?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 6&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Molecular dating is a difficult and advanced analysis. However, we can sometimes rely on fast methods for very large data sets or exploratory analysis. In the following, we root our tree of the marsupials and provide it to a fast dating method. We apply two calibrations: one for the root (65–90 Mya) and one for the split between Koalas and Wombats (2.5–5.5 Mya).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Root IQ-TREE inference&lt;br /&gt;
mars_tr &amp;amp;lt;- root(mars_gtr, &amp;quot;Opossum&amp;quot;, resolve.root = T)&lt;br /&gt;
&lt;br /&gt;
# Perform dating analysis&lt;br /&gt;
ctrl &amp;amp;lt;- chronos.control(dual.iter.max = 1000)&lt;br /&gt;
cal &amp;amp;lt;- data.frame(node = c(20, 12), age.min = c(2.5, 6.5), age.max = c(5.5, 9))&lt;br /&gt;
mars_dated &amp;amp;lt;- chronos(mars_tr, calibration = cal, control = ctrl)&lt;br /&gt;
mars_dated$edge.length &amp;amp;lt;- mars_dated$edge.length * 10&lt;br /&gt;
mars_dated$root.time &amp;amp;lt;- max(branching.times(mars_dated))&lt;br /&gt;
&lt;br /&gt;
# Plot dating analysis&lt;br /&gt;
pdf(&amp;quot;marsupials_dated.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
geoscalePhylo(&lt;br /&gt;
  mars_dated,&lt;br /&gt;
  units = c(&amp;quot;Period&amp;quot;, &amp;quot;Epoch&amp;quot;),&lt;br /&gt;
  boxes = &amp;quot;Epoch&amp;quot;,&lt;br /&gt;
  width = 3,&lt;br /&gt;
  cex.age = 1.5,&lt;br /&gt;
  cex.ts = 1.5,&lt;br /&gt;
  cex.tip = 1.5&lt;br /&gt;
)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q17.&amp;lt;/b&amp;gt; What do these date inferences suggest about the diversification of marsupials with relation to the Cretaceous/Palaeogene mass extinction event, or other major geological transitions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q18.&amp;lt;/b&amp;gt; What forms of uncertainty are missing in this dated tree figure, and how would you consider incorporating them?&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Solution&amp;diff=529</id>
		<title>Solution</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Solution&amp;diff=529"/>
		<updated>2026-01-11T07:37:45Z</updated>

		<summary type="html">&lt;p&gt;Mick: Created page with &amp;quot;&amp;lt;hr&amp;gt;  &amp;lt;h2&amp;gt;Answers&amp;lt;/h2&amp;gt;  &amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Marsupials Newick&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;  &amp;lt;pre&amp;gt; myTree &amp;amp;lt;- read.tree(text = &amp;quot;((Echidna,Platypus),(American_Opossums,(Monito_del_Monte,((((Koalas,Wombats),(Possums,(Kangaroos,Wallabies))),(((Bandicoots,Bilby),Marsupial_Mole),((Tasmanian_Devil,Tasmanian_Tiger),Numbats)))))));&amp;quot;) &amp;lt;/pre&amp;gt;  &amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; The two trees contain the same information about relationships, but the rooted tree additionally contains information about the most recent common ancestor of...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Answers&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Marsupials Newick&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;((Echidna,Platypus),(American_Opossums,(Monito_del_Monte,((((Koalas,Wombats),(Possums,(Kangaroos,Wallabies))),(((Bandicoots,Bilby),Marsupial_Mole),((Tasmanian_Devil,Tasmanian_Tiger),Numbats)))))));&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; The two trees contain the same information about relationships, but the rooted tree additionally contains information about the most recent common ancestor of the whole set (the root node), and this also adds the order of divergence events in time.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2.&amp;lt;/b&amp;gt; Branch lengths were not provided, so no information about amount of evolution or time can be drawn from these data.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3.&amp;lt;/b&amp;gt; The rooted tree gives information about the relative timing of events. For instance, we know that the Opossums were the first to diverge from all other marsupials.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4.&amp;lt;/b&amp;gt; We should prefer an unrooted tree unless we have strong confidence of the root placement in our data set. This is often done by trusting the signal from an unrelated “outgroup” taxon, but even this method can be misleading, such as if the outgroup is too unrelated and has a poor signal of placement among ingroup branches.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5.&amp;lt;/b&amp;gt; The unaligned data have different sequence lengths and do not contain gaps/indels. This means that we have not made an inference about the homology of sites in the data. Since homology is a fundamental assumption in phylogenetics, we cannot use the unaligned data for phylogenetic inference.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6.&amp;lt;/b&amp;gt; Regions that are difficult to align might have excess missing data, such that removing them can be beneficial. That is, we remove regions with excess uncertainty in alignment. Conversely, a small amount of missing data might indicate a genuine insertion/deletion, such that these regions can be highly informative and should not always be removed.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7.&amp;lt;/b&amp;gt; These lengths measure the summed amount of molecular change across the history of all samples in the data.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8.&amp;lt;/b&amp;gt; Gappy regions are often fast evolving or poorly aligned, such that they induce a greater amount of evolutionary change in inferences than complete data.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9.&amp;lt;/b&amp;gt; These methods do not lead to substantially different results. This can occur because the data are highly informative (or extremely uninformative). Another possible reason is that the parameter of interest is not difficult to infer. This is the case with phylogenetic tree topology, but phylogenetic branch lengths are more difficult, and this can be seen in modest differences among methods.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10.&amp;lt;/b&amp;gt; The GTR+R6 has more parameters and is therefore more complex. It also has a lower BIC score, suggesting that there is substantial complexity in these data that require multiple processes to be accounted for. Examining an even richer range of models could be beneficial.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11.&amp;lt;/b&amp;gt; The GTR+R6 model leads to a longer tree, suggesting that it can identify a greater number of evolutionary changes. Its lower BIC indicates that the simple JC model is failing to identify real change, probably because it does not incorporate realistic forms of variation such as rates across sites.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12.&amp;lt;/b&amp;gt; A–G and C–T changes are far more common than others. These are the two types transitions, which are comparatively energetically cheap and therefore expected to be far more common than transversions. The data set therefore follows a biochemical expectation.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q13.&amp;lt;/b&amp;gt; There is a portion (~13%) that is evolving 4 times faster than the mean in the data. These could be sites with poor alignment or with limited biological importance and therefore low selection constraints.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14.&amp;lt;/b&amp;gt; The analysis using GTR+R6 took twice the amount of time, suggesting that in a large data set it could place a substantial computational and energetic burden. If this is calculated as excessive, it might be necessary to find a compromise with a simpler model that nonetheless captures important forms of variation in the data (e.g., transitions and transversions).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q15.&amp;lt;/b&amp;gt; The branch supports suggest that these data offer limited confidence regarding some deep relationships among marsupial taxa. It seems particularly unclear whether the two types of possums are actually sisters, or whether the Monito del Monte is the sister to all other Australasian marsupials (versus embedded within them).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q16.&amp;lt;/b&amp;gt; The signal across gene trees is largely consistent with that of our inferences directly from nucleotide data. However, the gene trees have substantial uncertainty regarding one of the deepest marsupial nodes, suggesting either the data are insufficient or there was a near-simultaneous diversification event among multiple groups.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q17.&amp;lt;/b&amp;gt; The dates suggest that the split between American and Australasian marsupials occurred around the time of the final split of Gondwana. The Eocene and Oligocene saw the diversification of most of the major groupings of marsupials sampled.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q18.&amp;lt;/b&amp;gt; The figure does not show any uncertainty in the tree topology or in the timing of divergence events. The tree topology could be shown via bootstrap values or a “cloud” of trees, while uncertainty in divergence events could be shown as bars traversing the plausible time period.&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=528</id>
		<title>Exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise&amp;diff=528"/>
		<updated>2026-01-11T07:35:32Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Phylogenomics&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;David A. Duchene&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Marsupials are a group of mammals that are unique to Australasia and the Americas. Several major groups of marsupials first appeared between 50 and 70 million years ago, during events of fast diversification. Given these are ancient and fast events, resolving the relationships among early marsupials is difficult, and remains a matter of interest in mammalian biology.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Today&#039;s exercises focus on the most fundamental concepts in phylogenomics, with the aim of resolving longstanding questions of the evolution of Australasian marsupials.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s make sense of our current understanding of marsupial relationships by coding them in Newick format.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 1&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open R and load the required packages:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(ape)&lt;br /&gt;
library(strap)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create an object containing a Newick tree:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;WRITE NEWICK HERE&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To write this tree, follow the verbal description of marsupial relationships in Newick format:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The Wallabies are sisters to the Kangaroos, and this broader grouping is sister to the Possums. Sister to all these is the grouping that contains the Koalas and the Wombats. Yet another, separate group of marsupials contains the carnivorous Numbats, whose sister is a group containing the Tasmanian Devil and the now-extinct Tasmanian Tiger. It is hypothesised that that the sister to these carnivorous marsupials is a group containing the Marsupial Mole, whose closer sister is a group containing the Bandicoots and the Bilby. Sister to all of the marsupials mentioned so far is the enigmatic American Monito del Monte, and sister yet to all of these are the American Opossums. Finally, the Platypus and the Echidna form a group that is sister to all other mammals.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make sure you add a semicolon (&amp;lt;code&amp;gt;;&amp;lt;/code&amp;gt;) at the end of your tree. Now attempt to rearrange the names around so that they are in order of the least diverse to the most, while maintaining the relationships intact.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Compare your tree with the student sitting next to you. Discuss whether the Newick trees are different. Then evaluate whether the relationships in your trees are the same, even if the exact written text string is different.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you get too many errors, then use:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myTree &amp;amp;lt;- read.tree(text = &amp;quot;((Elephant,Armadillo),(((Squirrel,Rabbit),(Monkey,Treeshrew)),(Shrew,(Whale,(Bat,(Cat,Rhinoceros))))));&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now plot your tree into a PDF using two different representations:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;myTree.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(myTree, type = &amp;quot;phylogram&amp;quot;)&lt;br /&gt;
plot(myTree, type = &amp;quot;unrooted&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; Do the two trees in the file contain the same information?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2.&amp;lt;/b&amp;gt; Can you draw any information from the branch lengths in these trees?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3.&amp;lt;/b&amp;gt; What information about the timing of each of these divergence events is available in the first tree?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4.&amp;lt;/b&amp;gt; Which of the two trees might be the most appropriate in cases where you have little prior information about the data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 2&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Load two data alignments, and then open the basic information about them and visualize a small portion:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read data&lt;br /&gt;
unaligned_mars &amp;amp;lt;- read.FASTA(&amp;quot;marsupials_unaligned.fasta&amp;quot;)&lt;br /&gt;
aligned_mars &amp;amp;lt;- as.matrix(read.FASTA(&amp;quot;marsupials_aligned.fasta&amp;quot;))&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of unaligned data&lt;br /&gt;
###########################&lt;br /&gt;
unaligned_mars&lt;br /&gt;
&lt;br /&gt;
###########################&lt;br /&gt;
# Summary of aligned data&lt;br /&gt;
###########################&lt;br /&gt;
aligned_mars&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of unaligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(do.call(rbind, lapply(as.character(unaligned_mars), `[`, 1:10)))&lt;br /&gt;
&lt;br /&gt;
#########################&lt;br /&gt;
# Start of aligned data&lt;br /&gt;
#########################&lt;br /&gt;
noquote(as.character(aligned_mars)[1:11, 1:10])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5.&amp;lt;/b&amp;gt; What are the primary differences between these two alignments, and why is only one of them suitable for phylogenetic inference?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The following code will remove any alignment sites (columns) with missing data (aka gaps or indels). It then builds basic trees from the complete and filtered alignments using two methods (ordinary least squares, &amp;lt;code&amp;gt;ols&amp;lt;/code&amp;gt;, and balanced minimum evolution, &amp;lt;code&amp;gt;bme&amp;lt;/code&amp;gt;):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Filter out sites with missing data &lt;br /&gt;
filtered_mars &amp;amp;lt;- aligned_mars[, !colSums(as.character(aligned_mars) == &amp;quot;-&amp;quot;) &amp;amp;gt; 0]&lt;br /&gt;
&lt;br /&gt;
# Make matrices of pairwise distances between taxa&lt;br /&gt;
dists_full &amp;amp;lt;- dist.dna(aligned_mars, model = &amp;quot;K80&amp;quot;, pairwise.deletion = T)&lt;br /&gt;
dists_filt &amp;amp;lt;- dist.dna(filtered_mars, model = &amp;quot;K80&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Make trees for the two data sets, under two methods each&lt;br /&gt;
basicTrees &amp;amp;lt;- list()&lt;br /&gt;
basicTrees$full_ols &amp;amp;lt;- fastme.ols(dists_full)&lt;br /&gt;
basicTrees$full_bme &amp;amp;lt;- fastme.bal(dists_full)&lt;br /&gt;
basicTrees$filt_ols &amp;amp;lt;- fastme.ols(dists_filt)&lt;br /&gt;
basicTrees$filt_bme &amp;amp;lt;- fastme.bal(dists_filt)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6.&amp;lt;/b&amp;gt; Before looking at any of the trees, what do you think are the benefits and drawbacks of removing sites with missing data?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Try plotting a few of these trees with the approaches that you used in Exercise 1.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Next, we will look at the total lengths of these trees:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
lapply(basicTrees, function(x) sum(x$edge.length))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7.&amp;lt;/b&amp;gt; What do these tree lengths measure?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8.&amp;lt;/b&amp;gt; Why is there a difference between the filtered and unfiltered data sets?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Do not worry at this stage about the differences between the two methods, but if you have time discuss with your partner what the difference is and what it means for your interpretation of the data.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 3&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
From within R, let&#039;s run IQ-TREE 3 under two different substitution models, adding statistical supports for the branches (upcoming lecture):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Run maximum-likelihood with a very simple model&lt;br /&gt;
system(&amp;quot;iqtree3 -s marsupials_aligned.fasta -m JC -bb 1000 -pre mars_jc&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Run maximum-likelihood with a more complex model&lt;br /&gt;
system(&amp;quot;iqtree3 -s marsupials_aligned.fasta -m GTR+R6 -bb 1000 -pre mars_gtr&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s visualise the trees from the three different methods so far:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Read maximum likelihood trees&lt;br /&gt;
mars_jc &amp;amp;lt;- read.tree(&amp;quot;mars_jc.treefile&amp;quot;)&lt;br /&gt;
mars_gtr &amp;amp;lt;- read.tree(&amp;quot;mars_gtr.treefile&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot all four inferred trees into a PDF&lt;br /&gt;
pdf(&amp;quot;marsupial_trees.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
par(mfrow = c(2, 2))&lt;br /&gt;
plot(basicTrees$full_ols, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Ordinary Least Squares&amp;quot;)&lt;br /&gt;
plot(basicTrees$full_bme, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Balanced Min Evolution&amp;quot;)&lt;br /&gt;
plot(mars_jc, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (JC)&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9.&amp;lt;/b&amp;gt; Do you think that these methods lead to substantially different results? Lay out a few reasons for your answer.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 4&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Using the runs from the previous exercise, let&#039;s open the &amp;lt;code&amp;gt;.iqtree&amp;lt;/code&amp;gt; files from each run (you can then exit by pressing &amp;lt;code&amp;gt;q&amp;lt;/code&amp;gt;) and examine some of the details of the analyses.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Output summary for the run with the simple model&lt;br /&gt;
system(&amp;quot;less mars_jc.iqtree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Output summary for the run with the more complex model&lt;br /&gt;
system(&amp;quot;less mars_gtr.iqtree&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10.&amp;lt;/b&amp;gt; Which of the two models has more parameters (more complexity) and which model has the best BIC score (i.e. the lowest), and what does this tell you about the two models?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11.&amp;lt;/b&amp;gt; Does one model infer the total tree length to be much greater than the other? Discuss the possible reason for this with the student beside you.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12.&amp;lt;/b&amp;gt; From the GTR run and “Rate Parameter R”, which pairs of nucleotides has the most common type of substitution, and does this tell you anything about the biochemistry of the molecules analysed?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q13.&amp;lt;/b&amp;gt; From the same run and the “Model of rate heterogeneity”, are there any portions of the data that evolve much faster than the rest? Note that, for example, a relative rate of 2 means a portion of the data is evolving twice as fast as the mean.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14.&amp;lt;/b&amp;gt; From the time stamps at the bottom of this file, did one model take much longer than the other, and what could this mean if you have a very large data set?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Now let&#039;s examine the branch supports from one of these runs, using the tree that you loaded previously into R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pdf(&amp;quot;mars_branch_supports.pdf&amp;quot;)&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, use.edge.length = F)&lt;br /&gt;
nodelabels(mars_gtr$node.label, frame = &amp;quot;circle&amp;quot;, bg = &amp;quot;white&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q15.&amp;lt;/b&amp;gt; What does this tell you about our overall confidence in marsupial relationships from these data, and which are likely the most difficult relationships to resolve?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 5&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A previous set of analyses has led to the gene trees for several genomic regions. Read and briefly explore these data in R.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_trs &amp;amp;lt;- read.tree(&amp;quot;marsupials.tree&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
# Plot 9 randomly chosen trees from the set&lt;br /&gt;
pdf(&amp;quot;mars_example_gene_trees.pdf&amp;quot;, height = 15, width = 15)&lt;br /&gt;
par(mfrow = c(3, 3), mar = c(0.5, 0.5, 0.5, 0.5))&lt;br /&gt;
for(i in sample(1:length(mars_trs), 9)) plot(mars_trs[[i]], type = &amp;quot;unrooted&amp;quot;, cex = 1.5)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Examine the trees in the PDF and determine whether any of them have surprising relationships at deep branches.&lt;br /&gt;
Speculate on the possible causes of the discordance (hint: what could be the influence/relevance of the branch lengths?).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Let&#039;s use these trees and a fast consensus method of tree inference, and compare the tree with that from maximum likelihood.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mars_cons &amp;amp;lt;- consensus(mars_trs, p = 0.5)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;mars_main_trees.pdf&amp;quot;, height = 7, width = 14)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
plot(mars_gtr, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Max Likelihood (GTR)&amp;quot;)&lt;br /&gt;
plot(mars_cons, type = &amp;quot;unrooted&amp;quot;, main = &amp;quot;Majority-Rule Consensus&amp;quot;)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q16.&amp;lt;/b&amp;gt; How would you qualify the signal in the gene trees regarding the early branching events in the marsupial tree, and what do you think were the biological processes that led to this signal?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Exercise 6&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Molecular dating is a difficult and advanced analysis. However, we can sometimes rely on fast methods for very large data sets or exploratory analysis. In the following, we root our tree of the marsupials and provide it to a fast dating method. We apply two calibrations: one for the root (65–90 Mya) and one for the split between Koalas and Wombats (2.5–5.5 Mya).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Root IQ-TREE inference&lt;br /&gt;
mars_tr &amp;amp;lt;- root(mars_gtr, &amp;quot;Opossum&amp;quot;, resolve.root = T)&lt;br /&gt;
&lt;br /&gt;
# Perform dating analysis&lt;br /&gt;
ctrl &amp;amp;lt;- chronos.control(dual.iter.max = 1000)&lt;br /&gt;
cal &amp;amp;lt;- data.frame(node = c(20, 12), age.min = c(2.5, 6.5), age.max = c(5.5, 9))&lt;br /&gt;
mars_dated &amp;amp;lt;- chronos(mars_tr, calibration = cal, control = ctrl)&lt;br /&gt;
mars_dated$edge.length &amp;amp;lt;- mars_dated$edge.length * 10&lt;br /&gt;
mars_dated$root.time &amp;amp;lt;- max(branching.times(mars_dated))&lt;br /&gt;
&lt;br /&gt;
# Plot dating analysis&lt;br /&gt;
pdf(&amp;quot;marsupials_dated.pdf&amp;quot;, height = 10, width = 10)&lt;br /&gt;
geoscalePhylo(&lt;br /&gt;
  mars_dated,&lt;br /&gt;
  units = c(&amp;quot;Period&amp;quot;, &amp;quot;Epoch&amp;quot;),&lt;br /&gt;
  boxes = &amp;quot;Epoch&amp;quot;,&lt;br /&gt;
  width = 3,&lt;br /&gt;
  cex.age = 1.5,&lt;br /&gt;
  cex.ts = 1.5,&lt;br /&gt;
  cex.tip = 1.5&lt;br /&gt;
)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q17.&amp;lt;/b&amp;gt; What do these date inferences suggest about the diversification of marsupials with relation to the Cretaceous/Palaeogene mass extinction event, or other major geological transitions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q18.&amp;lt;/b&amp;gt; What forms of uncertainty are missing in this dated tree figure, and how would you consider incorporating them?&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=513</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=513"/>
		<updated>2026-01-09T19:01:34Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[ Microbial_genomics_exercise ]]) ([[ solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Questions]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercises]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Metabarcoding Exercise]]) ([[Metabarcoding Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test.pdf Test])([https://teaching.healthtech.dtu.dk/material/22126/2026/Recap_test_Answers.pdf Answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Ancient_DNA_exercise&amp;diff=512</id>
		<title>Ancient DNA exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Ancient_DNA_exercise&amp;diff=512"/>
		<updated>2026-01-09T10:18:44Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;H2&amp;gt;Overview&amp;lt;/H2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adapted from Martin Sikora.&lt;br /&gt;
&lt;br /&gt;
First:&lt;br /&gt;
&amp;lt;OL&amp;gt;&lt;br /&gt;
&amp;lt;LI&amp;gt;Navigate to your home directory:&lt;br /&gt;
&amp;lt;LI&amp;gt;Create a directory called &amp;quot;adna&amp;quot; &lt;br /&gt;
&amp;lt;LI&amp;gt;Navigate to the directory you just created.&lt;br /&gt;
&amp;lt;/OL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We will try to &lt;br /&gt;
# Authenticate ancient DNA&lt;br /&gt;
# do some basic population genetics&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Data authentication&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Authentication involves making sure that the DNA that you have extracted from my fossil and sequenced is indeed from the fossil and not some modern contaminant. A big difference between modern DNA and ancient DNA is the presence of chemical damage due to the passage of time. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt; Direct measurements of the rate of chemical damage&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, create a directory:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir  01_authentication&lt;br /&gt;
cd 01_authentication&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We will characterize DNA damage patterns using mapDamage, a software to estimate the rate of nucleotide substitution. In this section, we will examine some example BAM files for the presence of DNA damage patterns typical of ancient DNA.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have a set of 10 modern and 26 ancient individuals (subsampled to 100k reads)&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
find /home/projects/22126_NGS/exercises/adna/01_authentication/bam/ -name &amp;quot;*bam&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, run mapDamage on one of the modern individuals:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/apps/mapdamage2/2.2.3/venv/bin/mapDamage -i /home/projects/22126_NGS/exercises/adna/01_authentication/bam/modern/NA20786.mapped.ILLUMINA.bwa.TSI.low_coverage.20130415.100k_ss.bam -r /home/databases/references/human/hs37d5.fa --no-stats&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output &amp;lt;b&amp;gt;(either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd NA20786.mapped.ILLUMINA.bwa.TSI.low_coverage.20130415.100k_ss.mapDamage/&lt;br /&gt;
Length_plot.pdf&lt;br /&gt;
Fragmisincorporation_plot.pdf&lt;br /&gt;
cd ..&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q1:&#039;&#039;&#039; which fragment length occurs most frequently?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q2:&#039;&#039;&#039; what is the frequency of 5&#039; C&amp;gt;T and 3&#039; G&amp;gt;A substitutions ()&lt;br /&gt;
&lt;br /&gt;
Run mapDamage on one of the ancient individuals&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/apps/mapdamage2/2.2.3/venv/bin/mapDamage -i  /home/projects/22126_NGS/exercises/adna/01_authentication/bam/ancient/allentoft_2015/RISE559.sort.rmdup.realign.md.100k.bam -r /home/databases/references/human/hs37d5.fa --no-stats&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output &amp;lt;b&amp;gt;(either via mobaxterm or by downloading it locally)&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd RISE559.sort.rmdup.realign.md.100k.mapDamage/&lt;br /&gt;
Length_plot.pdf &lt;br /&gt;
Fragmisincorporation_plot.pdf &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q3:&#039;&#039;&#039; At what fragment length does the distribution show its peak?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q4:&#039;&#039;&#039; what are the frequencies of 5&#039; C&amp;gt;T (red line) and 3&#039; G&amp;gt;A substitutions (blue line)?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q5:&#039;&#039;&#039; which bases are enriched at 5&#039; flanking position?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q6:&#039;&#039;&#039; does your sample look ancient? if not, what might be the reason?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H2&amp;gt; Population genetics &amp;lt;/H2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a new subdirectory and navigate to it:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ..&lt;br /&gt;
mkdir 02_popgen&lt;br /&gt;
cd 02_popgen&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Explore the reference panel dataset&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Pur reference panel dataset is in binary PLINK format, a widely used format in genetic studies (see documentation [https://www.cog-genomics.org/plink/1.9/ here]). We need to access the following files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ls /home/projects/22126_NGS/exercises/adna/02_popgen/plink/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
However, instead of copying them, we will create symbolic links using the ln command, these acts as placeholders and tell the operating system to pretend that there is an actual file there. This saves considerable disk space compared to copying over the files. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.bed .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.bim .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.cluster .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.fam .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.sampleInfo.txt .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/eur.poplist .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/modern.poplist .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/noneur.poplist .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The PLINK binary format consists of 3 files:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;file&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;description&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
| world.bed&lt;br /&gt;
| | genotype data in binary format (&#039;&#039;&#039;not to be confused with genomic intervals bed file but it is confusing&#039;&#039;&#039;)&lt;br /&gt;
|-&lt;br /&gt;
| world.bim&lt;br /&gt;
| metadata for the variants, 1 line per variant&lt;br /&gt;
|-&lt;br /&gt;
| world.fam&lt;br /&gt;
| metadata for the samples, 1 line per sample&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We also have the following files than contain extra information:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;file&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;description&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
|world.cluster&lt;br /&gt;
| pre-defined population groupings for samples (for plink)&lt;br /&gt;
|-&lt;br /&gt;
| world.sampleInfo.txt&lt;br /&gt;
| additional sample metadata (for plotting etc)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Let us explore the metadata files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
head world.fam&lt;br /&gt;
head world.bim&lt;br /&gt;
head world.cluster&lt;br /&gt;
head world.sampleInfo.txt&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q7:&#039;&#039;&#039; How many samples / SNPs are in our dataset?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q8:&#039;&#039;&#039; what populations are in our reference panel and what sample size do they have (trick: forgo the header using &amp;quot;tail -n+2&amp;quot;, you need &amp;quot;sort&amp;quot; and uniq (prints 1 instance per repeated line), to tell &amp;quot;uniq&amp;quot; to count and print how many lines were repeated &amp;quot;-c&amp;quot;?&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Calculate basic summary statistics (a simple description of the data) for the dataset:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile world --missing --out world&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q9:&#039;&#039;&#039;  are you getting the same number of variants and individuals as you did via UNIX command lines?&lt;br /&gt;
&lt;br /&gt;
The world.imiss file lists the number and fraction of missing genotypes for each sample&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q10:&#039;&#039;&#039; what fraction of SNPs have a missing genotype for the Tyrolean Iceman?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Genotype and merge an ancient individual&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this section, we will merge our ancient data with the reference panel to prepare our dataset for downstream analysis genotypes for our ancient data will be obtained by randomly sampling a read from the alignments (BAM files) at the reference dataset SNP positions.&lt;br /&gt;
&lt;br /&gt;
We are going to use a low-coverage individual from [https://pubmed.ncbi.nlm.nih.gov/26062507/ Allentoft et al (RISE507)], this data was obtained from an ~5100-year-old individual from the Early Bronze Age [https://en.wikipedia.org/wiki/Afanasievo_culture Afanasievo culture] in the Altai Mountains region&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ls /home/projects/22126_NGS/exercises/adna/02_popgen/bam/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, we need to extract a genomic interval bed file for the SNP positions of the reference panel:&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
awk &#039;{print $1&amp;quot;\t&amp;quot;($4-1)&amp;quot;\t&amp;quot;$4}&#039; world.bim | gzip &amp;gt; world.snps.bed.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
awk is a command to create small programs. In this example, we tell it, print the first columns, the fourth column minus 1 and the fourth column again.&lt;br /&gt;
 &lt;br /&gt;
Inspect the results:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat world.snps.bed.gz | head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a read pileup file for the reference panel SNP positions (might take a few minutes) &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools mpileup -f /home/databases/references/human/hs37d5.fa -B -l world.snps.bed.gz /home/projects/22126_NGS/exercises/adna/02_popgen/bam/RISE507.sort.rmdup.realign.md.bam |gzip &amp;gt; RISE507.pileup.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.pileup.gz |head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q11&#039;&#039;&#039;: how many SNPs of the reference panel are covered in RISE507?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we will randomly sample a DNA fragment at each position and output the results in VCF format (custom python script):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.pileup.gz | /home/ctools/Python-2.7.18/bin/python2.7 /home/projects/22126_NGS/exercises/adna/02_popgen/get_haploid_vcf_from_pileup.py -r -s RISE507 |/home/ctools/htslib-1.20/bgzip -c &amp;gt; RISE507.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
This is done because the coverage is insufficient to ensure proper genotyping.&lt;br /&gt;
&lt;br /&gt;
Let us inspect the result:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.vcf.gz |grep -v &amp;quot;^#&amp;quot; |head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We convert to plink binary format:&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
/home/ctools/plink --vcf RISE507.vcf.gz --make-bed --double-id --out RISE507&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Try to merge the sample with the reference panel&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
/home/ctools/plink --bfile world --bmerge RISE507 --out RISE507.merge&lt;br /&gt;
&amp;lt;/pre&amp;gt; &lt;br /&gt;
&lt;br /&gt;
You should get an error.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q12&#039;&#039;&#039;: how many SNPs failed the merge? What is the likely reason?&lt;br /&gt;
&lt;br /&gt;
We will remove the failing SNPs and try again&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507 --exclude RISE507.merge.missnp --make-bed --out RISE507.merge2&lt;br /&gt;
/home/ctools/plink --bfile world --bmerge RISE507.merge2 --out RISE507.world&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Make a cluster file for subsetting&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
awk &#039;{print $1,$2,$1}&#039; RISE507.world.fam &amp;gt; RISE507.world.cluster&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Investigate the genetic affinities of the ancient sample using PCA&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this section, we will try to place our sample within a PCA of a set of modern and ancient individuals.&lt;br /&gt;
&lt;br /&gt;
First, we will have a look at the modern populations in the reference panel:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --keep-clusters modern.poplist --within RISE507.world.cluster --pca header tabs --out modern&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We can plot the first two principal components using the custom R script plotPca.R&lt;br /&gt;
&lt;br /&gt;
The three positional arguments are the eigenvector file, sample info file and prefix for the output &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R modern.eigenvec world.sampleInfo.txt modern&lt;br /&gt;
modern.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q13:&#039;&#039;&#039; which populations are most differentiated along PC1?&lt;br /&gt;
&#039;&#039;&#039;Q14:&#039;&#039;&#039; which populations are most differentiated along PC2?&lt;br /&gt;
&lt;br /&gt;
We repeat the exercise on a subset of European populations &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --keep-clusters eur.poplist --within RISE507.world.cluster --pca header tabs --out eur&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R eur.eigenvec world.sampleInfo.txt eur&lt;br /&gt;
eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q15:&#039;&#039;&#039; which populations are most differentiated along PC1?&lt;br /&gt;
&#039;&#039;&#039;Q16:&#039;&#039;&#039; which populations are most differentiated along PC2?&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Now, let us examine how the cluster of ancient individuals compared to the modern ones &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --pca header tabs --out ancient.world&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient.world.eigenvec world.sampleInfo.txt ancient.world&lt;br /&gt;
ancient.world.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here are some references if you want to read more about the different ancient samples:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;sample&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;link&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
| UstIshim&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Ust%27-Ishim_man]&lt;br /&gt;
|-&lt;br /&gt;
| Loschbour&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Loschbour_man] [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4170574/]&lt;br /&gt;
|-&lt;br /&gt;
| Brana&lt;br /&gt;
| [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4269527/]&lt;br /&gt;
|-&lt;br /&gt;
| NE1&lt;br /&gt;
| [https://www.pnas.org/content/113/2/368]&lt;br /&gt;
|-&lt;br /&gt;
|Stuttgart&lt;br /&gt;
| [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4170574/]&lt;br /&gt;
|-&lt;br /&gt;
| Iceman&lt;br /&gt;
| [https://www.iceman.it/en/the-iceman/]&lt;br /&gt;
|-&lt;br /&gt;
|Karelia&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Karelians]&lt;br /&gt;
|-&lt;br /&gt;
| Samara&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Samara_culture]&lt;br /&gt;
|-&lt;br /&gt;
| MA1&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Mal%27ta%E2%80%93Buret%27_culture]&lt;br /&gt;
|-&lt;br /&gt;
| RISE507&lt;br /&gt;
|[https://pubmed.ncbi.nlm.nih.gov/26062507/]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q17:&#039;&#039;&#039; which ancient individuals don&#039;t cluster close to any modern individuals? what could be a plausible reason?&lt;br /&gt;
&lt;br /&gt;
Repeat the exercise but remove the non-European modern individuals &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --within RISE507.world.cluster --remove-clusters noneur.poplist --pca header tabs --out ancient.eur&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient.eur.eigenvec world.sampleInfo.txt ancient.eur&lt;br /&gt;
ancient.eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q18:&#039;&#039;&#039; which populations are most differentiated along PC1? what could be a plausible reason?&lt;br /&gt;
&lt;br /&gt;
As a final exercise, we now project the ancient individual on PCs inferred from modern Europeans&amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --within RISE507.world.cluster --pca-clusters eur.poplist --remove-clusters noneur.poplist --pca header tabs --out ancient_proj.eur --maf 0.01&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient_proj.eur.eigenvec world.sampleInfo.txt ancient_proj.eur&lt;br /&gt;
ancient_proj.eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q19:&#039;&#039;&#039; where does our study individual cluster now?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q20:&#039;&#039;&#039; How do you explain that an individual that is found closer to the modern-day Chinese border is closer to modern Europeans than he is to the Han Chinese?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Please find answers [[Ancient_DNA_exercise_answers|here]]&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Ancient_DNA_exercise&amp;diff=511</id>
		<title>Ancient DNA exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Ancient_DNA_exercise&amp;diff=511"/>
		<updated>2026-01-09T10:07:16Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;H2&amp;gt;Overview&amp;lt;/H2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adapted from Martin Sikora.&lt;br /&gt;
&lt;br /&gt;
First:&lt;br /&gt;
&amp;lt;OL&amp;gt;&lt;br /&gt;
&amp;lt;LI&amp;gt;Navigate to your home directory:&lt;br /&gt;
&amp;lt;LI&amp;gt;Create a directory called &amp;quot;adna&amp;quot; &lt;br /&gt;
&amp;lt;LI&amp;gt;Navigate to the directory you just created.&lt;br /&gt;
&amp;lt;/OL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We will try to &lt;br /&gt;
# Authenticate ancient DNA&lt;br /&gt;
# do some basic population genetics&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Data authentication&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Authentication involves making sure that the DNA that you have extracted from my fossil and sequenced is indeed from the fossil and not some modern contaminant. A big difference between modern DNA and ancient DNA is the presence of chemical damage due to the passage of time. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt; Direct measurements of the rate of chemical damage&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, create a directory:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir  01_authentication&lt;br /&gt;
cd 01_authentication&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We will characterize DNA damage patterns using mapDamage, a software to estimate the rate of nucleotide substitution. In this section, we will examine some example BAM files for the presence of DNA damage patterns typical of ancient DNA.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have a set of 10 modern and 26 ancient individuals (subsampled to 100k reads)&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
find /home/projects/22126_NGS/exercises/adna/01_authentication/bam/ -name &amp;quot;*bam&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, run mapDamage on one of the modern individuals:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/apps/mapdamage2/2.2.3/venv/bin/mapDamage/mapDamage -i /home/projects/22126_NGS/exercises/adna/01_authentication/bam/modern/NA20786.mapped.ILLUMINA.bwa.TSI.low_coverage.20130415.100k_ss.bam -r /home/databases/references/human/hs37d5.fa --no-stats&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output &amp;lt;b&amp;gt;(either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd NA20786.mapped.ILLUMINA.bwa.TSI.low_coverage.20130415.100k_ss.mapDamage/&lt;br /&gt;
Length_plot.pdf&lt;br /&gt;
Fragmisincorporation_plot.pdf&lt;br /&gt;
cd ..&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q1:&#039;&#039;&#039; which fragment length occurs most frequently?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q2:&#039;&#039;&#039; what is the frequency of 5&#039; C&amp;gt;T and 3&#039; G&amp;gt;A substitutions ()&lt;br /&gt;
&lt;br /&gt;
Run mapDamage on one of the ancient individuals&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/apps/mapdamage2/2.2.3/venv/bin/mapDamage/mapDamage -i  /home/projects/22126_NGS/exercises/adna/01_authentication/bam/ancient/allentoft_2015/RISE559.sort.rmdup.realign.md.100k.bam -r /home/databases/references/human/hs37d5.fa --no-stats&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output &amp;lt;b&amp;gt;(either via mobaxterm or by downloading it locally)&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd RISE559.sort.rmdup.realign.md.100k.mapDamage/&lt;br /&gt;
Length_plot.pdf &lt;br /&gt;
Fragmisincorporation_plot.pdf &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q3:&#039;&#039;&#039; At what fragment length does the distribution show its peak?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q4:&#039;&#039;&#039; what are the frequencies of 5&#039; C&amp;gt;T (red line) and 3&#039; G&amp;gt;A substitutions (blue line)?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q5:&#039;&#039;&#039; which bases are enriched at 5&#039; flanking position?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q6:&#039;&#039;&#039; does your sample look ancient? if not, what might be the reason?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H2&amp;gt; Population genetics &amp;lt;/H2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a new subdirectory and navigate to it:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ..&lt;br /&gt;
mkdir 02_popgen&lt;br /&gt;
cd 02_popgen&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Explore the reference panel dataset&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Pur reference panel dataset is in binary PLINK format, a widely used format in genetic studies (see documentation [https://www.cog-genomics.org/plink/1.9/ here]). We need to access the following files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ls /home/projects/22126_NGS/exercises/adna/02_popgen/plink/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
However, instead of copying them, we will create symbolic links using the ln command, these acts as placeholders and tell the operating system to pretend that there is an actual file there. This saves considerable disk space compared to copying over the files. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.bed .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.bim .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.cluster .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.fam .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.sampleInfo.txt .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/eur.poplist .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/modern.poplist .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/noneur.poplist .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The PLINK binary format consists of 3 files:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;file&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;description&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
| world.bed&lt;br /&gt;
| | genotype data in binary format (&#039;&#039;&#039;not to be confused with genomic intervals bed file but it is confusing&#039;&#039;&#039;)&lt;br /&gt;
|-&lt;br /&gt;
| world.bim&lt;br /&gt;
| metadata for the variants, 1 line per variant&lt;br /&gt;
|-&lt;br /&gt;
| world.fam&lt;br /&gt;
| metadata for the samples, 1 line per sample&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We also have the following files than contain extra information:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;file&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;description&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
|world.cluster&lt;br /&gt;
| pre-defined population groupings for samples (for plink)&lt;br /&gt;
|-&lt;br /&gt;
| world.sampleInfo.txt&lt;br /&gt;
| additional sample metadata (for plotting etc)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Let us explore the metadata files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
head world.fam&lt;br /&gt;
head world.bim&lt;br /&gt;
head world.cluster&lt;br /&gt;
head world.sampleInfo.txt&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q7:&#039;&#039;&#039; How many samples / SNPs are in our dataset?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q8:&#039;&#039;&#039; what populations are in our reference panel and what sample size do they have (trick: forgo the header using &amp;quot;tail -n+2&amp;quot;, you need &amp;quot;sort&amp;quot; and uniq (prints 1 instance per repeated line), to tell &amp;quot;uniq&amp;quot; to count and print how many lines were repeated &amp;quot;-c&amp;quot;?&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Calculate basic summary statistics (a simple description of the data) for the dataset:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile world --missing --out world&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q9:&#039;&#039;&#039;  are you getting the same number of variants and individuals as you did via UNIX command lines?&lt;br /&gt;
&lt;br /&gt;
The world.imiss file lists the number and fraction of missing genotypes for each sample&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q10:&#039;&#039;&#039; what fraction of SNPs have a missing genotype for the Tyrolean Iceman?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Genotype and merge an ancient individual&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this section, we will merge our ancient data with the reference panel to prepare our dataset for downstream analysis genotypes for our ancient data will be obtained by randomly sampling a read from the alignments (BAM files) at the reference dataset SNP positions.&lt;br /&gt;
&lt;br /&gt;
We are going to use a low-coverage individual from [https://pubmed.ncbi.nlm.nih.gov/26062507/ Allentoft et al (RISE507)], this data was obtained from an ~5100-year-old individual from the Early Bronze Age [https://en.wikipedia.org/wiki/Afanasievo_culture Afanasievo culture] in the Altai Mountains region&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ls /home/projects/22126_NGS/exercises/adna/02_popgen/bam/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, we need to extract a genomic interval bed file for the SNP positions of the reference panel:&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
awk &#039;{print $1&amp;quot;\t&amp;quot;($4-1)&amp;quot;\t&amp;quot;$4}&#039; world.bim | gzip &amp;gt; world.snps.bed.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
awk is a command to create small programs. In this example, we tell it, print the first columns, the fourth column minus 1 and the fourth column again.&lt;br /&gt;
 &lt;br /&gt;
Inspect the results:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat world.snps.bed.gz | head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a read pileup file for the reference panel SNP positions (might take a few minutes) &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools mpileup -f /home/databases/references/human/hs37d5.fa -B -l world.snps.bed.gz /home/projects/22126_NGS/exercises/adna/02_popgen/bam/RISE507.sort.rmdup.realign.md.bam |gzip &amp;gt; RISE507.pileup.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.pileup.gz |head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q11&#039;&#039;&#039;: how many SNPs of the reference panel are covered in RISE507?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we will randomly sample a DNA fragment at each position and output the results in VCF format (custom python script):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.pileup.gz | /home/ctools/Python-2.7.18/bin/python2.7 /home/projects/22126_NGS/exercises/adna/02_popgen/get_haploid_vcf_from_pileup.py -r -s RISE507 |/home/ctools/htslib-1.20/bgzip -c &amp;gt; RISE507.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
This is done because the coverage is insufficient to ensure proper genotyping.&lt;br /&gt;
&lt;br /&gt;
Let us inspect the result:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.vcf.gz |grep -v &amp;quot;^#&amp;quot; |head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We convert to plink binary format:&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
/home/ctools/plink --vcf RISE507.vcf.gz --make-bed --double-id --out RISE507&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Try to merge the sample with the reference panel&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
/home/ctools/plink --bfile world --bmerge RISE507 --out RISE507.merge&lt;br /&gt;
&amp;lt;/pre&amp;gt; &lt;br /&gt;
&lt;br /&gt;
You should get an error.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q12&#039;&#039;&#039;: how many SNPs failed the merge? What is the likely reason?&lt;br /&gt;
&lt;br /&gt;
We will remove the failing SNPs and try again&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507 --exclude RISE507.merge.missnp --make-bed --out RISE507.merge2&lt;br /&gt;
/home/ctools/plink --bfile world --bmerge RISE507.merge2 --out RISE507.world&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Make a cluster file for subsetting&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
awk &#039;{print $1,$2,$1}&#039; RISE507.world.fam &amp;gt; RISE507.world.cluster&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Investigate the genetic affinities of the ancient sample using PCA&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this section, we will try to place our sample within a PCA of a set of modern and ancient individuals.&lt;br /&gt;
&lt;br /&gt;
First, we will have a look at the modern populations in the reference panel:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --keep-clusters modern.poplist --within RISE507.world.cluster --pca header tabs --out modern&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We can plot the first two principal components using the custom R script plotPca.R&lt;br /&gt;
&lt;br /&gt;
The three positional arguments are the eigenvector file, sample info file and prefix for the output &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R modern.eigenvec world.sampleInfo.txt modern&lt;br /&gt;
modern.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q13:&#039;&#039;&#039; which populations are most differentiated along PC1?&lt;br /&gt;
&#039;&#039;&#039;Q14:&#039;&#039;&#039; which populations are most differentiated along PC2?&lt;br /&gt;
&lt;br /&gt;
We repeat the exercise on a subset of European populations &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --keep-clusters eur.poplist --within RISE507.world.cluster --pca header tabs --out eur&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R eur.eigenvec world.sampleInfo.txt eur&lt;br /&gt;
eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q15:&#039;&#039;&#039; which populations are most differentiated along PC1?&lt;br /&gt;
&#039;&#039;&#039;Q16:&#039;&#039;&#039; which populations are most differentiated along PC2?&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Now, let us examine how the cluster of ancient individuals compared to the modern ones &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --pca header tabs --out ancient.world&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient.world.eigenvec world.sampleInfo.txt ancient.world&lt;br /&gt;
ancient.world.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here are some references if you want to read more about the different ancient samples:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;sample&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;link&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
| UstIshim&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Ust%27-Ishim_man]&lt;br /&gt;
|-&lt;br /&gt;
| Loschbour&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Loschbour_man] [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4170574/]&lt;br /&gt;
|-&lt;br /&gt;
| Brana&lt;br /&gt;
| [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4269527/]&lt;br /&gt;
|-&lt;br /&gt;
| NE1&lt;br /&gt;
| [https://www.pnas.org/content/113/2/368]&lt;br /&gt;
|-&lt;br /&gt;
|Stuttgart&lt;br /&gt;
| [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4170574/]&lt;br /&gt;
|-&lt;br /&gt;
| Iceman&lt;br /&gt;
| [https://www.iceman.it/en/the-iceman/]&lt;br /&gt;
|-&lt;br /&gt;
|Karelia&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Karelians]&lt;br /&gt;
|-&lt;br /&gt;
| Samara&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Samara_culture]&lt;br /&gt;
|-&lt;br /&gt;
| MA1&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Mal%27ta%E2%80%93Buret%27_culture]&lt;br /&gt;
|-&lt;br /&gt;
| RISE507&lt;br /&gt;
|[https://pubmed.ncbi.nlm.nih.gov/26062507/]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q17:&#039;&#039;&#039; which ancient individuals don&#039;t cluster close to any modern individuals? what could be a plausible reason?&lt;br /&gt;
&lt;br /&gt;
Repeat the exercise but remove the non-European modern individuals &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --within RISE507.world.cluster --remove-clusters noneur.poplist --pca header tabs --out ancient.eur&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient.eur.eigenvec world.sampleInfo.txt ancient.eur&lt;br /&gt;
ancient.eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q18:&#039;&#039;&#039; which populations are most differentiated along PC1? what could be a plausible reason?&lt;br /&gt;
&lt;br /&gt;
As a final exercise, we now project the ancient individual on PCs inferred from modern Europeans&amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --within RISE507.world.cluster --pca-clusters eur.poplist --remove-clusters noneur.poplist --pca header tabs --out ancient_proj.eur --maf 0.01&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient_proj.eur.eigenvec world.sampleInfo.txt ancient_proj.eur&lt;br /&gt;
ancient_proj.eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q19:&#039;&#039;&#039; where does our study individual cluster now?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q20:&#039;&#039;&#039; How do you explain that an individual that is found closer to the modern-day Chinese border is closer to modern Europeans than he is to the Han Chinese?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Please find answers [[Ancient_DNA_exercise_answers|here]]&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=509</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=509"/>
		<updated>2026-01-09T08:48:36Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([https://teaching.healthtech.dtu.dk/material/22126/2026/3D_Genomics_Workshop.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[ Microbial_genomics_exercise ]]) ([[ solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Questions]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercises]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Metabarcoding Exercise]]) ([[Metabarcoding Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024.pdf Test 2025])([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024_withA.pdf answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=508</id>
		<title>Exercise and answers</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=508"/>
		<updated>2026-01-09T08:09:07Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt;&lt;br /&gt;
([https://pubmed.ncbi.nlm.nih.gov/28723903/ Serra et al., 2017]):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Slurm / sbatch on the cluster&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The cluster uses &amp;lt;b&amp;gt;Slurm&amp;lt;/b&amp;gt; to schedule jobs. Instead of running long commands directly in the terminal,&lt;br /&gt;
you write a small script (an &amp;lt;code&amp;gt;.sbatch&amp;lt;/code&amp;gt; file) that requests resources (time, CPUs, memory) and runs your commands.&lt;br /&gt;
Slurm decides when and where your job runs so users don’t interfere with each other.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After you submit a job you can safely disconnect without your job crashing (similar idea to &amp;lt;code&amp;gt;screen&amp;lt;/code&amp;gt;).&lt;br /&gt;
Slurm writes standard output and errors to log files, so you can always see what happened.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;sbatch myjob.sbatch&amp;lt;/code&amp;gt; — submit a job (returns a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;squeue -u $USER&amp;lt;/code&amp;gt; — check your jobs&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;scancel &amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt; — cancel a job&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;You may get notified something is missing — just accept.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
eval &amp;quot;$(/home/ctools/miniconda3/bin/conda shell.bash hook)&amp;quot;&lt;br /&gt;
conda activate &amp;quot;$HOME/envs/tadbit_course&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch \&lt;br /&gt;
  /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the new copy with your favourite editor (for example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;)&lt;br /&gt;
and paste the following at the &amp;lt;b&amp;gt;bottom&amp;lt;/b&amp;gt; of the file &amp;lt;b&amp;gt;after&amp;lt;/b&amp;gt; the existing &amp;lt;code&amp;gt;#SBATCH ...&amp;lt;/code&amp;gt; lines.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&lt;br /&gt;
cd ${data_dir}&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 \&lt;br /&gt;
  -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna \&lt;br /&gt;
  -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you were to run this, you would submit the job with:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK INSTEAD.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem \&lt;br /&gt;
  /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna \&lt;br /&gt;
  /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While the indexing step would run, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt; from the template:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 01_fastp.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt; and paste the following at the bottom (after the &amp;lt;code&amp;gt;#SBATCH&amp;lt;/code&amp;gt; lines):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Launch fastp: raw reads are read from course folder, clean fastqs are stored in your folder.&lt;br /&gt;
# Enable adapter detection; trim the first 5 bases (often lower quality).&lt;br /&gt;
# Use 4 threads and minimum read length 30 (remove reads shorter than this after trimming).&lt;br /&gt;
fastp \&lt;br /&gt;
  -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
  -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
  -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
  -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
  --detect_adapter_for_pe \&lt;br /&gt;
  --trim_front1 5 \&lt;br /&gt;
  -w 4 \&lt;br /&gt;
  -l 30 \&lt;br /&gt;
  -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the script to the queue:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 01_fastp.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
When it finishes, copy the HTML report to your local computer and open it in a browser&lt;br /&gt;
(replace &amp;lt;code&amp;gt;SERVER&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;USER&amp;lt;/code&amp;gt; as needed):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp USER@SERVER:/home/people/USER/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; It should be about ~96.4%. No massive adapter content or low quality sequences. After mapping we will inspect ligation/digestion patterns in more detail.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create &amp;lt;code&amp;gt;02_map.sbatch&amp;lt;/code&amp;gt; from the template and add the commands below (paste at the bottom after &amp;lt;code&amp;gt;#SBATCH&amp;lt;/code&amp;gt; lines).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 02_map.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment (double digestion)&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 02_map.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to inspect the job output, check the log files in &amp;lt;code&amp;gt;SCRIPTS/log&amp;lt;/code&amp;gt; (or the directory where you submitted the job,&lt;br /&gt;
depending on the template). TADbit also produces PNG plots inside &amp;lt;code&amp;gt;tadbit_dirs/liver/&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Cutting frequency differs between 4-cutters and 6-cutters and influences fragment size distribution, ligation probabilities, and contact resolution. Using two enzymes increases the diversity of ligation junctions. Compare with Micro-C, which uses MNase digestion, so it cuts evenly through the genome.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Useful background figures (open locally):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;[https://teaching.healthtech.dtu.dk/material/22126/2026/Fragment_histogram.pdf Fragment size histogram]&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;[https://teaching.healthtech.dtu.dk/material/22126/2026/ligation_deconvolution.png Hi-C sequencing quality: digestion/ligation deconvolution ]&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note on runtime:&amp;lt;/b&amp;gt; this step can be quick or can take longer depending on load and filesystem performance.&lt;br /&gt;
Try to get it launched, then continue reading / looking at the provided plots while it runs (this is a good time for a break).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create &amp;lt;code&amp;gt;03_parse.sbatch&amp;lt;/code&amp;gt; from the template and (important!) update the template to request &amp;lt;b&amp;gt;10 CPUs&amp;lt;/b&amp;gt;&lt;br /&gt;
(e.g. change &amp;lt;code&amp;gt;#SBATCH -c 4&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;#SBATCH -c 10&amp;lt;/code&amp;gt;), then paste the commands below at the bottom.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 03_parse.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/home/people/$USER/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
&lt;br /&gt;
tadbit parse \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --genome ${ref} \&lt;br /&gt;
  --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
  --compress_input&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 03_parse.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Consider complex ligation products (read pairs mapping to different fragments in the same molecule, i.e., multiple contacts) and multi-mapping artifacts; TADbit focuses on valid pairs as operationally defined by the filters. Multi-contact methods (e.g., Pore-C, SPRITE) address this explicitly, but standard Hi-C largely models binary contacts per ligation event. We can view it on the bam file in the next step.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
To see what the filter numbers mean, check:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter --help&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Run filtering (you can run in an sbatch script or interactively):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
cd tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Check the “valid pairs” section of &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; after filtering to get the exact count and percentage.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Because a read pair can be assigned to more than one category (e.g., a dangling end that is also a duplicate). Categories are not mutually exclusive, so percentages can overlap.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create an sbatch script (e.g. &amp;lt;code&amp;gt;04_norm_vanilla.sbatch&amp;lt;/code&amp;gt;) if you like, then paste the commands below at the bottom.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 04_norm_vanilla.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Normalization method&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&lt;br /&gt;
tadbit normalize \&lt;br /&gt;
  -w ${wd} \&lt;br /&gt;
  -r ${res} \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
  --normalization ${norm} \&lt;br /&gt;
  --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
  --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 04_norm_vanilla.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Optional reading on normalization strategies:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
[https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105 Overview article on Hi-C normalization strategies]&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
This step can take a while, so using an sbatch script is recommended.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 05_bin_chr1.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
res=&amp;quot;100000&amp;quot;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
tadbit bin \&lt;br /&gt;
  -w ${wd} \&lt;br /&gt;
  -r ${res} \&lt;br /&gt;
  -c ${chrom} \&lt;br /&gt;
  --plot \&lt;br /&gt;
  --norm ${norm} \&lt;br /&gt;
  --format &amp;quot;png&amp;quot; \&lt;br /&gt;
  --cpus 6&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 05_bin_chr1.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Example matrices (open locally):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;[https://teaching.healthtech.dtu.dk/material/22126/2026/Raw_HiC.png Raw Hi-C matrix] &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;[https://teaching.healthtech.dtu.dk/material/22126/2026/Normal_HiC.png Normalized Hi-C matrix] &amp;lt;/li&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=507</id>
		<title>Exercise and answers</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=507"/>
		<updated>2026-01-09T08:02:44Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt;&lt;br /&gt;
(&amp;lt;a href=&amp;quot;https://pubmed.ncbi.nlm.nih.gov/28723903/&amp;quot; target=&amp;quot;_blank&amp;quot; rel=&amp;quot;noopener&amp;quot;&amp;gt;Serra et al., 2017&amp;lt;/a&amp;gt;):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Slurm / sbatch on the cluster&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The cluster uses &amp;lt;b&amp;gt;Slurm&amp;lt;/b&amp;gt; to schedule jobs. Instead of running long commands directly in the terminal,&lt;br /&gt;
you write a small script (an &amp;lt;code&amp;gt;.sbatch&amp;lt;/code&amp;gt; file) that requests resources (time, CPUs, memory) and runs your commands.&lt;br /&gt;
Slurm decides when and where your job runs so users don’t interfere with each other.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After you submit a job you can safely disconnect without your job crashing (similar idea to &amp;lt;code&amp;gt;screen&amp;lt;/code&amp;gt;).&lt;br /&gt;
Slurm writes standard output and errors to log files, so you can always see what happened.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;sbatch myjob.sbatch&amp;lt;/code&amp;gt; — submit a job (returns a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;squeue -u $USER&amp;lt;/code&amp;gt; — check your jobs&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;scancel &amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt; — cancel a job&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;You may get notified something is missing — just accept.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
eval &amp;quot;$(/home/ctools/miniconda3/bin/conda shell.bash hook)&amp;quot;&lt;br /&gt;
conda activate &amp;quot;$HOME/envs/tadbit_course&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch \&lt;br /&gt;
  /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the new copy with your favourite editor (for example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;)&lt;br /&gt;
and paste the following at the &amp;lt;b&amp;gt;bottom&amp;lt;/b&amp;gt; of the file &amp;lt;b&amp;gt;after&amp;lt;/b&amp;gt; the existing &amp;lt;code&amp;gt;#SBATCH ...&amp;lt;/code&amp;gt; lines.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&lt;br /&gt;
cd ${data_dir}&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 \&lt;br /&gt;
  -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna \&lt;br /&gt;
  -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you were to run this, you would submit the job with:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK INSTEAD.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem \&lt;br /&gt;
  /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna \&lt;br /&gt;
  /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While the indexing step would run, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt; from the template:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 01_fastp.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt; and paste the following at the bottom (after the &amp;lt;code&amp;gt;#SBATCH&amp;lt;/code&amp;gt; lines):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Launch fastp: raw reads are read from course folder, clean fastqs are stored in your folder.&lt;br /&gt;
# Enable adapter detection; trim the first 5 bases (often lower quality).&lt;br /&gt;
# Use 4 threads and minimum read length 30 (remove reads shorter than this after trimming).&lt;br /&gt;
fastp \&lt;br /&gt;
  -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
  -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
  -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
  -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
  --detect_adapter_for_pe \&lt;br /&gt;
  --trim_front1 5 \&lt;br /&gt;
  -w 4 \&lt;br /&gt;
  -l 30 \&lt;br /&gt;
  -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the script to the queue:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 01_fastp.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
When it finishes, copy the HTML report to your local computer and open it in a browser&lt;br /&gt;
(replace &amp;lt;code&amp;gt;SERVER&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;USER&amp;lt;/code&amp;gt; as needed):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp USER@SERVER:/home/people/USER/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; It should be about ~96.4%. No massive adapter content or low quality sequences. After mapping we will inspect ligation/digestion patterns in more detail.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create &amp;lt;code&amp;gt;02_map.sbatch&amp;lt;/code&amp;gt; from the template and add the commands below (paste at the bottom after &amp;lt;code&amp;gt;#SBATCH&amp;lt;/code&amp;gt; lines).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 02_map.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment (double digestion)&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 02_map.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to inspect the job output, check the log files in &amp;lt;code&amp;gt;SCRIPTS/log&amp;lt;/code&amp;gt; (or the directory where you submitted the job,&lt;br /&gt;
depending on the template). TADbit also produces PNG plots inside &amp;lt;code&amp;gt;tadbit_dirs/liver/&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Cutting frequency differs between 4-cutters and 6-cutters and influences fragment size distribution, ligation probabilities, and contact resolution. Using two enzymes increases the diversity of ligation junctions. Compare with Micro-C, which uses MNase digestion, so it cuts evenly through the genome.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Useful background figures (open locally):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;https://teaching.healthtech.dtu.dk/material/22126/2026/Fragment_histogram.pdf&amp;quot; target=&amp;quot;_blank&amp;quot; rel=&amp;quot;noopener&amp;quot;&amp;gt;Fragment size histogram (PDF)&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;https://teaching.healthtech.dtu.dk/material/22126/2026/ligation_deconvolution.png&amp;quot; target=&amp;quot;_blank&amp;quot; rel=&amp;quot;noopener&amp;quot;&amp;gt;Hi-C sequencing quality: digestion/ligation deconvolution (PNG)&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note on runtime:&amp;lt;/b&amp;gt; this step can be quick or can take longer depending on load and filesystem performance.&lt;br /&gt;
Try to get it launched, then continue reading / looking at the provided plots while it runs (this is a good time for a break).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create &amp;lt;code&amp;gt;03_parse.sbatch&amp;lt;/code&amp;gt; from the template and (important!) update the template to request &amp;lt;b&amp;gt;10 CPUs&amp;lt;/b&amp;gt;&lt;br /&gt;
(e.g. change &amp;lt;code&amp;gt;#SBATCH -c 4&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;#SBATCH -c 10&amp;lt;/code&amp;gt;), then paste the commands below at the bottom.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 03_parse.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/home/people/$USER/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
&lt;br /&gt;
tadbit parse \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --genome ${ref} \&lt;br /&gt;
  --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
  --compress_input&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 03_parse.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Consider complex ligation products (read pairs mapping to different fragments in the same molecule, i.e., multiple contacts) and multi-mapping artifacts; TADbit focuses on valid pairs as operationally defined by the filters. Multi-contact methods (e.g., Pore-C, SPRITE) address this explicitly, but standard Hi-C largely models binary contacts per ligation event. We can view it on the bam file in the next step.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
To see what the filter numbers mean, check:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter --help&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Run filtering (you can run in an sbatch script or interactively):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
cd tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Check the “valid pairs” section of &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; after filtering to get the exact count and percentage.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Because a read pair can be assigned to more than one category (e.g., a dangling end that is also a duplicate). Categories are not mutually exclusive, so percentages can overlap.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Create an sbatch script (e.g. &amp;lt;code&amp;gt;04_norm_vanilla.sbatch&amp;lt;/code&amp;gt;) if you like, then paste the commands below at the bottom.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 04_norm_vanilla.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Normalization method&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&lt;br /&gt;
tadbit normalize \&lt;br /&gt;
  -w ${wd} \&lt;br /&gt;
  -r ${res} \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
  --normalization ${norm} \&lt;br /&gt;
  --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
  --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 04_norm_vanilla.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Optional reading on normalization strategies:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;a href=&amp;quot;https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&amp;quot; target=&amp;quot;_blank&amp;quot; rel=&amp;quot;noopener&amp;quot;&amp;gt;&lt;br /&gt;
Overview article on Hi-C normalization strategies&lt;br /&gt;
&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
This step can take a while, so using an sbatch script is recommended.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
cp template.sbatch 05_bin_chr1.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;&lt;br /&gt;
res=&amp;quot;100000&amp;quot;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
tadbit bin \&lt;br /&gt;
  -w ${wd} \&lt;br /&gt;
  -r ${res} \&lt;br /&gt;
  -c ${chrom} \&lt;br /&gt;
  --plot \&lt;br /&gt;
  --norm ${norm} \&lt;br /&gt;
  --format &amp;quot;png&amp;quot; \&lt;br /&gt;
  --cpus 6&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 05_bin_chr1.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Example matrices (open locally):&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;https://teaching.healthtech.dtu.dk/material/22126/2026/Raw_HiC.png&amp;quot; target=&amp;quot;_blank&amp;quot; rel=&amp;quot;noopener&amp;quot;&amp;gt;Raw Hi-C matrix (PNG)&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;https://teaching.healthtech.dtu.dk/material/22126/2026/Normal_HiC.png&amp;quot; target=&amp;quot;_blank&amp;quot; rel=&amp;quot;noopener&amp;quot;&amp;gt;Normalized Hi-C matrix (PNG)&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=417</id>
		<title>Denovo exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=417"/>
		<updated>2026-01-08T10:26:24Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to the directory you just created.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise we will perform a &amp;lt;b&amp;gt;de novo assembly&amp;lt;/b&amp;gt; of Illumina paired-end reads. The data is from a &amp;lt;i&amp;gt;Vibrio cholerae&amp;lt;/i&amp;gt; strain isolated in Nepal. You will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run FastQC and perform adapter/quality trimming (optional recap of pre-processing).&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Count k-mers and estimate genome size.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Correct reads using Musket.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Determine insert size of paired-end reads.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run de novo assembly using MEGAHIT.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Calculate assembly statistics.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Plot coverage and length histograms of the assembly.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Evaluate the assembly quality.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Visualize the assembly using Circoletto.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;(Bonus) Try assembling the genome with SPAdes.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Annotation of a prokaryotic genome.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;FastQC and trimming&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Make sure you are in the &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt; directory you created. You can double-check with:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pwd&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the sequencing data:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/* .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run FastQC on the reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing FastQC HTML reports:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the FastQC HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_1_sequence_fastqc.html .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_2_sequence_fastqc.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;There are several issues with this dataset (you do not need to study the report in detail now). We will clean it up first. Let’s identify the quality encoding:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_detect_fq.sh Vchol-001_6_1_sequence.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1. Which quality encoding format is used?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Trim the reads using AdapterRemoval. The most frequent adapter/primer sequences are already included below. We use a minimum read length of 40 nt, trim to quality 20, and specify quality base 64. The &amp;lt;code&amp;gt;--basename&amp;lt;/code&amp;gt; option defines the output prefix and &amp;lt;code&amp;gt;--gzip&amp;lt;/code&amp;gt; compresses the output.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/adapterremoval-2.3.4/build/AdapterRemoval \&lt;br /&gt;
  --file1 Vchol-001_6_1_sequence.txt.gz \&lt;br /&gt;
  --file2 Vchol-001_6_2_sequence.txt.gz \&lt;br /&gt;
  --adapter1 GATCGGAAGAGCACACGTCTGAACTCCAGTCACATCACGATATCGTATGC \&lt;br /&gt;
  --adapter2 GATCGGAAGAGCGTCGTGTAGGGAAAGAGGGTAGATCTCGGTGGTCGCCG \&lt;br /&gt;
  --qualitybase 64 \&lt;br /&gt;
  --basename Vchol-001_6 \&lt;br /&gt;
  --gzip \&lt;br /&gt;
  --trimqualities \&lt;br /&gt;
  --minquality 20 \&lt;br /&gt;
  --minlength 40&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When it finishes, inspect &amp;lt;code&amp;gt;Vchol-001_6.settings&amp;lt;/code&amp;gt; for trimming statistics (how many reads were trimmed, discarded, etc.).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1A. The output includes &amp;lt;code&amp;gt;discarded.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair1.truncated.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair2.truncated.gz&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;singleton.truncated.gz&amp;lt;/code&amp;gt;. What types of reads does each file contain? (Tip: check the AdapterRemoval documentation.)&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, compute basic read stats (average read length, min/max length, number of reads, total bases) for the trimmed paired reads. Note down the average read length and total number of bases:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair1.truncated.gz&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair2.truncated.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Genome size estimation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will count k-mers in the data. A k-mer is simply a DNA word of length k. We use &amp;lt;b&amp;gt;jellyfish&amp;lt;/b&amp;gt; to count 15-mers. We combine counts from forward and reverse-complement strands and then create a histogram. (This may take some time to run so could be good time to practice using &amp;quot;screen&amp;quot;)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Manual: [http://www.cbcb.umd.edu/software/jellyfish/jellyfish-manual.html jellyfish]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip -dc Vchol-001_6.pair*.truncated.gz \&lt;br /&gt;
  | /home/ctools/jellyfish-2.3.1/bin/jellyfish count -t 2 -m 15 -s 1000000000 -o Vchol-001 -C /dev/fd/0&lt;br /&gt;
&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish histo Vchol-001 &amp;gt; Vchol-001.histo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;Vchol-001.histo&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;Vchol-001.histo.pdf&amp;quot;)&lt;br /&gt;
barplot(dat[,2],&lt;br /&gt;
        xlim = c(0,150),&lt;br /&gt;
        ylim = c(0,5e5),&lt;br /&gt;
        ylab = &amp;quot;No of kmers&amp;quot;,&lt;br /&gt;
        xlab = &amp;quot;Counts of a k-mer&amp;quot;,&lt;br /&gt;
        names.arg = dat[,1],&lt;br /&gt;
        cex.names = 0.8)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the pdf files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/Vchol-001.histo.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The plot shows:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;x-axis: how many times a k-mer occurs (its count)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;y-axis: number of distinct k-mers with that count&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;K-mers that occur only a few times are typically due to sequencing errors. K-mers forming the main peak (higher counts) are likely “real” and can be used for error correction and genome size estimation.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2. Where is the k-mer coverage peak (approximately)?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We can estimate genome size using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
N = (M * L) / (L - K + 1)&lt;br /&gt;
Genome_size = T / N&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;N&amp;lt;/b&amp;gt; = depth (coverage)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;M&amp;lt;/b&amp;gt; = k-mer peak (from the histogram)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;K&amp;lt;/b&amp;gt; = k-mer size (here: 15)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;L&amp;lt;/b&amp;gt; = average read length (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;T&amp;lt;/b&amp;gt; = total number of bases (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute the estimated genome size and compare with the known &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome (~4 Mb). You should be within roughly ±10%.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3. What is your estimated genome size?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Error correction&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will correct errors in the reads using &amp;lt;b&amp;gt;Musket&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Musket: [http://musket.sourceforge.net/homepage.htm Musket]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, get the number of distinct k-mers (needed for memory allocation in Musket):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish stats Vchol-001&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the reported number of distinct k-mers (here an example: &amp;lt;code&amp;gt;8423098&amp;lt;/code&amp;gt;) in the Musket command:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/musket-1.1/musket -k 15 8423098 -p 1 -omulti Vchol-001_6.cor -inorder \&lt;br /&gt;
  Vchol-001_6.pair1.truncated.gz Vchol-001_6.pair2.truncated.gz -zlib 1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output files are named &amp;lt;code&amp;gt;Vchol-001_6.cor.0&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;Vchol-001_6.cor.1&amp;lt;/code&amp;gt;. Rename them:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mv Vchol-001_6.cor.0 Vchol-001_6.pair1.cor.truncated.fq.gz&lt;br /&gt;
mv Vchol-001_6.cor.1 Vchol-001_6.pair2.cor.truncated.fq.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;If this takes too long, you can copy precomputed corrected reads:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/corrected/Vchol-001_6.pair*.cor.truncated.fq.gz .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;&amp;lt;i&amp;gt;De novo&amp;lt;/i&amp;gt; assembly with MEGAHIT&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now assemble the corrected reads using &amp;lt;b&amp;gt;MEGAHIT&amp;lt;/b&amp;gt; (a de Bruijn graph assembler). K-mer size is critical: MEGAHIT can test multiple k-mers by default, but here we start with a fixed k-mer size of 35.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, set the number of threads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run MEGAHIT with k=35:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list 35 \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o 35&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When finished, you should have &amp;lt;code&amp;gt;35/final.contigs.fa&amp;lt;/code&amp;gt;. Compress it:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip 35/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To estimate insert size, we will map a subset of reads back to the assembly (similar to the alignment exercise). We’ll subsample the first 100,000 read pairs (400,000 lines per FASTQ):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat Vchol-001_6.pair1.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_1.fastq&lt;br /&gt;
zcat Vchol-001_6.pair2.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_2.fastq&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the assembly and map:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bwa index 35/final.contigs.fa.gz&lt;br /&gt;
&lt;br /&gt;
bwa mem 35/final.contigs.fa.gz Vchol_sample_1.fastq Vchol_sample_2.fastq \&lt;br /&gt;
  | samtools view -Sb - &amp;gt; Vchol_35bp.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract insert sizes (TLEN field, column 9):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view Vchol_35bp.bam | cut -f9 &amp;gt; initial.insertsizes.txt&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
a   = read.table(&amp;quot;initial.insertsizes.txt&amp;quot;)&lt;br /&gt;
a.v = a[a[,1] &amp;gt; 0, 1]&lt;br /&gt;
mn  = quantile(a.v, seq(0,1,0.05))[4]&lt;br /&gt;
mx  = quantile(a.v, seq(0,1,0.05))[18]&lt;br /&gt;
mean(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])   # mean insert size&lt;br /&gt;
sd(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])     # standard deviation&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4. What are the mean insert size and standard deviation of the library?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we will explore different k-mer sizes. Each student chooses a different k-mer from this Google sheet:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://docs.google.com/spreadsheets/d/1trUMlSwNLoNW67D-OkgA93iOQRp2iioyJSBYyW30P4U/edit?usp=sharing Google sheet for k-mer assignment]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Write your name next to the k-mer you select, then run MEGAHIT with that k-mer, replacing &amp;lt;code&amp;gt;[KMER]&amp;lt;/code&amp;gt; below:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list [KMER] \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o [KMER]&lt;br /&gt;
&lt;br /&gt;
gzip [KMER]/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute assembly statistics using &amp;lt;code&amp;gt;QUAST&amp;lt;/code&amp;gt; - note: quast does not consider contigs smaller than 500bp:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
 [KMER]/final.contigs.fa.gz \&lt;br /&gt;
 --threads 1 \&lt;br /&gt;
 -o [KMER]/quast&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the file &amp;lt;code&amp;gt;[KMER]/quast/report.txt&amp;lt;/code&amp;gt; (or &amp;lt;code&amp;gt;report.tsv&amp;lt;/code&amp;gt;) and&lt;br /&gt;
record the following values in the Google sheet for your k-mer:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Number of contigs (&amp;amp;ge; 500 bp)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Total assembly length&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Largest contig&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;N50&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;As a class, compare results across k-mer sizes and discuss which k-mer produces&lt;br /&gt;
the most reasonable assembly and why.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the best assembly to your folder, or use a precomputed multi-k assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.fa.gz .&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.stats .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5. How does the N50 of the best assembly (multi-k or default) compare to the N50 from the fixed-k assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6. How does the longest contig length compare between fixed-k and multi-k/default assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Coverage of the assembly&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now calculate per-contig coverage and lengths, and visualize them in R.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat default_final.contigs.fa.gz | /home/ctools/bin/fastx_megahit.sh --i /dev/stdin &amp;gt; default_finalt.cov&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(plotrix)&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;default_finalt.cov&amp;quot;, sep = &amp;quot;\t&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
## ---- Coverage plots (2 panels) ----&lt;br /&gt;
pdf(&amp;quot;best.coverage.pdf&amp;quot;, width = 10, height = 5)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
&lt;br /&gt;
weighted.hist(w = dat[,2],&lt;br /&gt;
              x = dat[,1],&lt;br /&gt;
              breaks = seq(0, 100, 1),&lt;br /&gt;
              main = &amp;quot;Weighted coverage&amp;quot;,&lt;br /&gt;
              xlab = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
hist(dat[,1],&lt;br /&gt;
     xlim   = c(0, 100),&lt;br /&gt;
     breaks = seq(0, 1000, 1),&lt;br /&gt;
     main   = &amp;quot;Raw coverage&amp;quot;,&lt;br /&gt;
     xlab   = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&lt;br /&gt;
## ---- Scaffold lengths (1 panel) ----&lt;br /&gt;
pdf(&amp;quot;scaffold.lengths.pdf&amp;quot;, width = 7, height = 5)&lt;br /&gt;
par(mfrow = c(1, 1))&lt;br /&gt;
&lt;br /&gt;
barplot(rev(sort(dat[,2])),&lt;br /&gt;
        xlab = &amp;quot;# Scaffold&amp;quot;,&lt;br /&gt;
        ylab = &amp;quot;Length&amp;quot;,&lt;br /&gt;
        main = &amp;quot;Scaffold Lengths&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;View the plots:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing the PDF files:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the PDF files directly from the&lt;br /&gt;
left-hand file panel.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the PDF files to your&lt;br /&gt;
local computer and open them with any PDF viewer. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/best.coverage.pdf .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/scaffold.lengths.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The left plot shows length-weighted coverage: long contigs contribute more to the histogram. The right plot shows the raw distribution of contig coverage. Typically, most of the assembly will cluster around the expected coverage (e.g. ~60–90×), and shorter contigs will have more variable coverage. The scaffold length plot shows that most of the assembled bases are in relatively long scaffolds.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7. Why might some short contigs have much &amp;lt;i&amp;gt;higher&amp;lt;/i&amp;gt; coverage than the rest of the assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8. Why might some short contigs have much &amp;lt;i&amp;gt;lower&amp;lt;/i&amp;gt; coverage than the rest of the assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Assembly evaluation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use &amp;lt;b&amp;gt;QUAST&amp;lt;/b&amp;gt; to evaluate the assembly using various reference-based metrics.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;QUAST: [https://quast.sourceforge.net/quast quast]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run QUAST against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
  default_final.contigs.fa.gz \&lt;br /&gt;
  --threads 1 \&lt;br /&gt;
  -R /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/quast_results/latest/report.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9. The report lists several misassemblies. Can we always fully trust these “misassembly” calls? Why or why not?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Visualization using Circoletto&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will visualize the assembly against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference using Circoletto.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, filter out contigs shorter than 500 bp:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_filterfasta.sh default_final.contigs.fa.gz 500 &amp;gt; default_final.contigs_filtered_500.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;On your local machine, open a browser and go to:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://bat.infspire.org/circoletto/ Circoletto]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the filtered assembly in a text editor on the server, for example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit default_final.contigs_filtered_500.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste the FASTA content into the &amp;lt;b&amp;gt;“Query fasta”&amp;lt;/b&amp;gt; box on the Circoletto page.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then open the reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste this into the &amp;lt;b&amp;gt;“Subject fasta”&amp;lt;/b&amp;gt; box.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In the “Output” section, select &amp;lt;b&amp;gt;“ONLY show the best hit per query”&amp;lt;/b&amp;gt;, then click &amp;lt;b&amp;gt;Submit to Circoletto&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If Circoletto does not work, you can use this precomputed image:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/denovo/circoletto_results/cl0011524231.blasted.png&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You should see the two &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; chromosomes on the left (labelled with “gi|…”) and the alignment of your contigs to these chromosomes. Colours represent BLAST bitscores (red = high confidence, black = low).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10. Does your assembled genome appear broadly similar to the reference genome?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11. Are there contigs/scaffolds that do not map, or only partially map, to the reference?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12. On chromosome 2 (the smaller chromosome), there may be a region with many short, low-confidence hits. What might this region represent? Hint: see the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome paper and search for “V. cholerae integron island”: [https://www.nature.com/articles/35020000 V. cholerae genome paper]&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Try to assemble the genome using SPAdes (bonus)&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Different assemblers can perform very differently. &amp;lt;b&amp;gt;SPAdes&amp;lt;/b&amp;gt; is widely used and generally performs well. It performs error correction and uses multiple k-mer sizes internally.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;SPAdes: [https://ablab.github.io/spades/ SPAdes]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Check the help output:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/SPAdes-4.2.0-Linux/bin/spades.py -h&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; A full SPAdes run may take ~45 minutes. You can use the precomputed SPAdes assembly instead and compare to MEGAHIT using QUAST and Assemblathon stats.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Link to the SPAdes assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/denovo/vchol/spades/spades.fasta spades.fasta&lt;br /&gt;
# from here you can compute stats and run QUAST&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Annotation of a prokaryotic genome&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will annotate genes in &amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/denovo/canu/ecoli_pacbio.contigs.fasta&amp;lt;/code&amp;gt; using &amp;lt;b&amp;gt;prodigal&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Prodigal: [https://bmcbioinformatics.biomedcentral.com/articles/10.1186/1471-2105-11-119 prodigal]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output will be a GFF file with gene coordinates and a FASTA file with predicted proteins:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/Prodigal/prodigal \&lt;br /&gt;
  -f gff \&lt;br /&gt;
  -i [input genome in fasta] \&lt;br /&gt;
  -a [output proteins in fasta] \&lt;br /&gt;
  -o [output annotations in gff]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;GFF format: [https://www.ensembl.org/info/website/upload/gff.html GFF format description]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, index the protein FASTA file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract the protein sequence for gene ID &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa tig00000001_4582&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use BLASTP against the nr database:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://blast.ncbi.nlm.nih.gov/Blast.cgi?PROGRAM=blastp&amp;amp;PAGE_TYPE=BlastSearch&amp;amp;LINK_LOC=blasthome BLAST for proteins]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Paste the sequence and run BLASTP.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14. Which protein (function) does &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt; correspond to?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please find answers here: [[Denovo_solution|Denovo_solution]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=413</id>
		<title>Denovo exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=413"/>
		<updated>2026-01-08T10:20:00Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to the directory you just created.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise we will perform a &amp;lt;b&amp;gt;de novo assembly&amp;lt;/b&amp;gt; of Illumina paired-end reads. The data is from a &amp;lt;i&amp;gt;Vibrio cholerae&amp;lt;/i&amp;gt; strain isolated in Nepal. You will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run FastQC and perform adapter/quality trimming (optional recap of pre-processing).&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Count k-mers and estimate genome size.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Correct reads using Musket.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Determine insert size of paired-end reads.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run de novo assembly using MEGAHIT.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Calculate assembly statistics.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Plot coverage and length histograms of the assembly.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Evaluate the assembly quality.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Visualize the assembly using Circoletto.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;(Bonus) Try assembling the genome with SPAdes.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Annotation of a prokaryotic genome.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;FastQC and trimming&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Make sure you are in the &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt; directory you created. You can double-check with:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pwd&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the sequencing data:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/* .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run FastQC on the reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing FastQC HTML reports:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the FastQC HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_1_sequence_fastqc.html .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_2_sequence_fastqc.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;There are several issues with this dataset (you do not need to study the report in detail now). We will clean it up first. Let’s identify the quality encoding:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_detect_fq.sh Vchol-001_6_1_sequence.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1. Which quality encoding format is used?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Trim the reads using AdapterRemoval. The most frequent adapter/primer sequences are already included below. We use a minimum read length of 40 nt, trim to quality 20, and specify quality base 64. The &amp;lt;code&amp;gt;--basename&amp;lt;/code&amp;gt; option defines the output prefix and &amp;lt;code&amp;gt;--gzip&amp;lt;/code&amp;gt; compresses the output.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/adapterremoval-2.3.4/build/AdapterRemoval \&lt;br /&gt;
  --file1 Vchol-001_6_1_sequence.txt.gz \&lt;br /&gt;
  --file2 Vchol-001_6_2_sequence.txt.gz \&lt;br /&gt;
  --adapter1 GATCGGAAGAGCACACGTCTGAACTCCAGTCACATCACGATATCGTATGC \&lt;br /&gt;
  --adapter2 GATCGGAAGAGCGTCGTGTAGGGAAAGAGGGTAGATCTCGGTGGTCGCCG \&lt;br /&gt;
  --qualitybase 64 \&lt;br /&gt;
  --basename Vchol-001_6 \&lt;br /&gt;
  --gzip \&lt;br /&gt;
  --trimqualities \&lt;br /&gt;
  --minquality 20 \&lt;br /&gt;
  --minlength 40&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When it finishes, inspect &amp;lt;code&amp;gt;Vchol-001_6.settings&amp;lt;/code&amp;gt; for trimming statistics (how many reads were trimmed, discarded, etc.).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1A. The output includes &amp;lt;code&amp;gt;discarded.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair1.truncated.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair2.truncated.gz&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;singleton.truncated.gz&amp;lt;/code&amp;gt;. What types of reads does each file contain? (Tip: check the AdapterRemoval documentation.)&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, compute basic read stats (average read length, min/max length, number of reads, total bases) for the trimmed paired reads. Note down the average read length and total number of bases:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair1.truncated.gz&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair2.truncated.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Genome size estimation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will count k-mers in the data. A k-mer is simply a DNA word of length k. We use &amp;lt;b&amp;gt;jellyfish&amp;lt;/b&amp;gt; to count 15-mers. We combine counts from forward and reverse-complement strands and then create a histogram. (This may take some time to run so could be good time to practice using &amp;quot;screen&amp;quot;)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Manual: [http://www.cbcb.umd.edu/software/jellyfish/jellyfish-manual.html jellyfish]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip -dc Vchol-001_6.pair*.truncated.gz \&lt;br /&gt;
  | /home/ctools/jellyfish-2.3.1/bin/jellyfish count -t 2 -m 15 -s 1000000000 -o Vchol-001 -C /dev/fd/0&lt;br /&gt;
&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish histo Vchol-001 &amp;gt; Vchol-001.histo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;Vchol-001.histo&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;Vchol-001.histo.pdf&amp;quot;)&lt;br /&gt;
barplot(dat[,2],&lt;br /&gt;
        xlim = c(0,150),&lt;br /&gt;
        ylim = c(0,5e5),&lt;br /&gt;
        ylab = &amp;quot;No of kmers&amp;quot;,&lt;br /&gt;
        xlab = &amp;quot;Counts of a k-mer&amp;quot;,&lt;br /&gt;
        names.arg = dat[,1],&lt;br /&gt;
        cex.names = 0.8)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the pdf files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/Vchol-001.histo.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The plot shows:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;x-axis: how many times a k-mer occurs (its count)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;y-axis: number of distinct k-mers with that count&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;K-mers that occur only a few times are typically due to sequencing errors. K-mers forming the main peak (higher counts) are likely “real” and can be used for error correction and genome size estimation.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2. Where is the k-mer coverage peak (approximately)?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We can estimate genome size using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
N = (M * L) / (L - K + 1)&lt;br /&gt;
Genome_size = T / N&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;N&amp;lt;/b&amp;gt; = depth (coverage)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;M&amp;lt;/b&amp;gt; = k-mer peak (from the histogram)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;K&amp;lt;/b&amp;gt; = k-mer size (here: 15)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;L&amp;lt;/b&amp;gt; = average read length (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;T&amp;lt;/b&amp;gt; = total number of bases (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute the estimated genome size and compare with the known &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome (~4 Mb). You should be within roughly ±10%.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3. What is your estimated genome size?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Error correction&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will correct errors in the reads using &amp;lt;b&amp;gt;Musket&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Musket: [http://musket.sourceforge.net/homepage.htm Musket]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, get the number of distinct k-mers (needed for memory allocation in Musket):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish stats Vchol-001&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the reported number of distinct k-mers (here an example: &amp;lt;code&amp;gt;8423098&amp;lt;/code&amp;gt;) in the Musket command:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/musket-1.1/musket -k 15 8423098 -p 1 -omulti Vchol-001_6.cor -inorder \&lt;br /&gt;
  Vchol-001_6.pair1.truncated.gz Vchol-001_6.pair2.truncated.gz -zlib 1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output files are named &amp;lt;code&amp;gt;Vchol-001_6.cor.0&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;Vchol-001_6.cor.1&amp;lt;/code&amp;gt;. Rename them:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mv Vchol-001_6.cor.0 Vchol-001_6.pair1.cor.truncated.fq.gz&lt;br /&gt;
mv Vchol-001_6.cor.1 Vchol-001_6.pair2.cor.truncated.fq.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;If this takes too long, you can copy precomputed corrected reads:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/corrected/Vchol-001_6.pair*.cor.truncated.fq.gz .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;&amp;lt;i&amp;gt;De novo&amp;lt;/i&amp;gt; assembly with MEGAHIT&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now assemble the corrected reads using &amp;lt;b&amp;gt;MEGAHIT&amp;lt;/b&amp;gt; (a de Bruijn graph assembler). K-mer size is critical: MEGAHIT can test multiple k-mers by default, but here we start with a fixed k-mer size of 35.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, set the number of threads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run MEGAHIT with k=35:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list 35 \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o 35&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When finished, you should have &amp;lt;code&amp;gt;35/final.contigs.fa&amp;lt;/code&amp;gt;. Compress it:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip 35/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To estimate insert size, we will map a subset of reads back to the assembly (similar to the alignment exercise). We’ll subsample the first 100,000 read pairs (400,000 lines per FASTQ):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat Vchol-001_6.pair1.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_1.fastq&lt;br /&gt;
zcat Vchol-001_6.pair2.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_2.fastq&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the assembly and map:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bwa index 35/final.contigs.fa.gz&lt;br /&gt;
&lt;br /&gt;
bwa mem 35/final.contigs.fa.gz Vchol_sample_1.fastq Vchol_sample_2.fastq \&lt;br /&gt;
  | samtools view -Sb - &amp;gt; Vchol_35bp.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract insert sizes (TLEN field, column 9):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view Vchol_35bp.bam | cut -f9 &amp;gt; initial.insertsizes.txt&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
a   = read.table(&amp;quot;initial.insertsizes.txt&amp;quot;)&lt;br /&gt;
a.v = a[a[,1] &amp;gt; 0, 1]&lt;br /&gt;
mn  = quantile(a.v, seq(0,1,0.05))[4]&lt;br /&gt;
mx  = quantile(a.v, seq(0,1,0.05))[18]&lt;br /&gt;
mean(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])   # mean insert size&lt;br /&gt;
sd(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])     # standard deviation&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4. What are the mean insert size and standard deviation of the library?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we will explore different k-mer sizes. Each student chooses a different k-mer from this Google sheet:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://docs.google.com/spreadsheets/d/1trUMlSwNLoNW67D-OkgA93iOQRp2iioyJSBYyW30P4U/edit?usp=sharing Google sheet for k-mer assignment]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Write your name next to the k-mer you select, then run MEGAHIT with that k-mer, replacing &amp;lt;code&amp;gt;[KMER]&amp;lt;/code&amp;gt; below:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list [KMER] \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o [KMER]&lt;br /&gt;
&lt;br /&gt;
gzip [KMER]/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute assembly statistics using &amp;lt;code&amp;gt;QUAST&amp;lt;/code&amp;gt; - note: quast does not consider contigs smaller than 500bp:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
 [KMER]/final.contigs.fa.gz \&lt;br /&gt;
 --threads 1 \&lt;br /&gt;
 -o [KMER]/quast&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the file &amp;lt;code&amp;gt;[KMER]/quast/report.txt&amp;lt;/code&amp;gt; (or &amp;lt;code&amp;gt;report.tsv&amp;lt;/code&amp;gt;) and&lt;br /&gt;
record the following values in the Google sheet for your k-mer:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Number of contigs (&amp;amp;ge; 500 bp)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Total assembly length&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Largest contig&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;N50&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;As a class, compare results across k-mer sizes and discuss which k-mer produces&lt;br /&gt;
the most reasonable assembly and why.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the best assembly to your folder, or use a precomputed multi-k assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.fa.gz .&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.stats .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5. How does the N50 of the best assembly (multi-k or default) compare to the N50 from the fixed-k assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6. How does the longest contig length compare between fixed-k and multi-k/default assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Coverage of the assembly&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now calculate per-contig coverage and lengths, and visualize them in R.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat default_final.contigs.fa.gz | /home/ctools/bin/fastx_megahit.sh --i /dev/stdin &amp;gt; default_finalt.cov&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(plotrix)&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;default_finalt.cov&amp;quot;, sep = &amp;quot;\t&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
## ---- Coverage plots (2 panels) ----&lt;br /&gt;
pdf(&amp;quot;best.coverage.pdf&amp;quot;, width = 10, height = 5)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
&lt;br /&gt;
weighted.hist(w = dat[,2],&lt;br /&gt;
              x = dat[,1],&lt;br /&gt;
              breaks = seq(0, 100, 1),&lt;br /&gt;
              main = &amp;quot;Weighted coverage&amp;quot;,&lt;br /&gt;
              xlab = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
hist(dat[,1],&lt;br /&gt;
     xlim   = c(0, 100),&lt;br /&gt;
     breaks = seq(0, 1000, 1),&lt;br /&gt;
     main   = &amp;quot;Raw coverage&amp;quot;,&lt;br /&gt;
     xlab   = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&lt;br /&gt;
## ---- Scaffold lengths (1 panel) ----&lt;br /&gt;
pdf(&amp;quot;scaffold.lengths.pdf&amp;quot;, width = 7, height = 5)&lt;br /&gt;
par(mfrow = c(1, 1))&lt;br /&gt;
&lt;br /&gt;
barplot(rev(sort(dat[,2])),&lt;br /&gt;
        xlab = &amp;quot;# Scaffold&amp;quot;,&lt;br /&gt;
        ylab = &amp;quot;Length&amp;quot;,&lt;br /&gt;
        main = &amp;quot;Scaffold Lengths&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;View the plots:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing the PDF files:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the PDF files directly from the&lt;br /&gt;
left-hand file panel.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the PDF files to your&lt;br /&gt;
local computer and open them with any PDF viewer. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/best.coverage.pdf .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/scaffold.lengths.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The left plot shows length-weighted coverage: long contigs contribute more to the histogram. The right plot shows the raw distribution of contig coverage. Typically, most of the assembly will cluster around the expected coverage (e.g. ~60–90×), and shorter contigs will have more variable coverage. The scaffold length plot shows that most of the assembled bases are in relatively long scaffolds.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7. Why might some short contigs have much &amp;lt;i&amp;gt;higher&amp;lt;/i&amp;gt; coverage than the main assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8. Why might some short contigs have much &amp;lt;i&amp;gt;lower&amp;lt;/i&amp;gt; coverage than the main assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Assembly evaluation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use &amp;lt;b&amp;gt;QUAST&amp;lt;/b&amp;gt; to evaluate the assembly using various reference-based metrics.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;QUAST: [https://quast.sourceforge.net/quast quast]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run QUAST against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
  default_final.contigs.fa.gz \&lt;br /&gt;
  --threads 1 \&lt;br /&gt;
  -R /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/quast_results/latest/report.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9. The report lists several misassemblies. Can we always fully trust these “misassembly” calls? Why or why not?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Visualization using Circoletto&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will visualize the assembly against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference using Circoletto.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, filter out contigs shorter than 500 bp:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_filterfasta.sh default_final.contigs.fa.gz 500 &amp;gt; default_final.contigs_filtered_500.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;On your local machine, open a browser and go to:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://bat.infspire.org/circoletto/ Circoletto]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the filtered assembly in a text editor on the server, for example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit default_final.contigs_filtered_500.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste the FASTA content into the &amp;lt;b&amp;gt;“Query fasta”&amp;lt;/b&amp;gt; box on the Circoletto page.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then open the reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste this into the &amp;lt;b&amp;gt;“Subject fasta”&amp;lt;/b&amp;gt; box.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In the “Output” section, select &amp;lt;b&amp;gt;“ONLY show the best hit per query”&amp;lt;/b&amp;gt;, then click &amp;lt;b&amp;gt;Submit to Circoletto&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If Circoletto does not work, you can use this precomputed image:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/denovo/circoletto_results/cl0011524231.blasted.png&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You should see the two &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; chromosomes on the left (labelled with “gi|…”) and the alignment of your contigs to these chromosomes. Colours represent BLAST bitscores (red = high confidence, black = low).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10. Does your assembled genome appear broadly similar to the reference genome?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11. Are there contigs/scaffolds that do not map, or only partially map, to the reference?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12. On chromosome 2 (the smaller chromosome), there may be a region with many short, low-confidence hits. What might this region represent? Hint: see the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome paper and search for “V. cholerae integron island”: [https://www.nature.com/articles/35020000 V. cholerae genome paper]&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Try to assemble the genome using SPAdes (bonus)&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Different assemblers can perform very differently. &amp;lt;b&amp;gt;SPAdes&amp;lt;/b&amp;gt; is widely used and generally performs well. It performs error correction and uses multiple k-mer sizes internally.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;SPAdes: [https://ablab.github.io/spades/ SPAdes]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Check the help output:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/SPAdes-4.2.0-Linux/bin/spades.py -h&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; A full SPAdes run may take ~45 minutes. You can use the precomputed SPAdes assembly instead and compare to MEGAHIT using QUAST and Assemblathon stats.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Link to the SPAdes assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/denovo/vchol/spades/spades.fasta spades.fasta&lt;br /&gt;
# from here you can compute stats and run QUAST&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Annotation of a prokaryotic genome&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will annotate genes in &amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/denovo/canu/ecoli_pacbio.contigs.fasta&amp;lt;/code&amp;gt; using &amp;lt;b&amp;gt;prodigal&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Prodigal: [https://bmcbioinformatics.biomedcentral.com/articles/10.1186/1471-2105-11-119 prodigal]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output will be a GFF file with gene coordinates and a FASTA file with predicted proteins:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/Prodigal/prodigal \&lt;br /&gt;
  -f gff \&lt;br /&gt;
  -i [input genome in fasta] \&lt;br /&gt;
  -a [output proteins in fasta] \&lt;br /&gt;
  -o [output annotations in gff]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;GFF format: [https://www.ensembl.org/info/website/upload/gff.html GFF format description]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, index the protein FASTA file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract the protein sequence for gene ID &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa tig00000001_4582&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use BLASTP against the nr database:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://blast.ncbi.nlm.nih.gov/Blast.cgi?PROGRAM=blastp&amp;amp;PAGE_TYPE=BlastSearch&amp;amp;LINK_LOC=blasthome BLAST for proteins]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Paste the sequence and run BLASTP.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14. Which protein (function) does &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt; correspond to?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please find answers here: [[Denovo_solution|Denovo_solution]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=399</id>
		<title>Exercise and answers</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=399"/>
		<updated>2026-01-08T09:23:36Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt; &amp;lt;b&amp;gt;You will get notified something is missing, just accept&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
eval &amp;quot;$(/home/ctools/miniconda3/bin/conda shell.bash hook)&amp;quot;&lt;br /&gt;
conda activate &amp;quot;$HOME/envs/tadbit_course&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
# also a log folder for the scripts&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
# Filtered fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the template with your favorite editor, paste the following into the file, and save it.&lt;br /&gt;
For example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE;&lt;br /&gt;
cd ${data_dir};&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We can make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5–10 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A prepared script is also available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ~/3D_GENOMICS_COURSE/SCRIPTS;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch .;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While genome indexing runs, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the template and create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/01_fastp.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into the SBATCH script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
fastp \&lt;br /&gt;
    # Read raw fastq from course folders&lt;br /&gt;
    -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
    # Store the clean fastq version in your folder&lt;br /&gt;
    -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
    -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
    -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
    --detect_adapter_for_pe \&lt;br /&gt;
    # Trim first 5 bases (often lower quality)&lt;br /&gt;
    --trim_front1 5 \&lt;br /&gt;
    # Threads&lt;br /&gt;
    -w 10 \&lt;br /&gt;
    # Minimal read length (remove reads shorter than this after trimming)&lt;br /&gt;
    -l 30 \&lt;br /&gt;
    -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the HTML report to your local computer and open it in a browser:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
USER=&amp;quot;juanrod&amp;quot;&lt;br /&gt;
scp ${USER}@pupil1.healthtech.dtu.dk:/home/people/${USER}/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; It should be about ~96.4%. No massive adapter content or low quality sequences. After mapping we will inspect ligation/digestion patterns in more detail.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into your mapping script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for mapping&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;  # Double digestion (relevant for Arima/Phase Genomics)&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1;&lt;br /&gt;
&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --tmpdb ${TMPDIR} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
# &amp;gt;&amp;gt;&amp;gt; Just change the script to take that as a parameter.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; We are not using iterative mapping. Fragment-based mapping is the default in TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Cutting frequency differs between 4‑cutters and 6‑cutters and influences fragment size distribution, ligation probabilities, and contact resolution. Using two enzymes increases the diversity of ligation junctions. Compare with Micro‑C, which uses MNase digestion, so it cuts evenly through the genome.&amp;lt;/p&amp;gt;&lt;br /&gt;
[https://teaching.healthtech.dtu.dk/material/22126/2026/Fragment_histogram.pdf Fragment size histogram]&lt;br /&gt;
[https://teaching.healthtech.dtu.dk/material/22126/2026/ligation_deconvolution.png HiC Sequencing Quality and digestion - ligation deconvolution]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Fragment size histogram&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HiC sequencing quality and digestion/ligation deconvolution&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
ref=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# Keep only canonical chromosomes and compress map files after parsing&lt;br /&gt;
tadbit parse \&lt;br /&gt;
       --workdir ${wd} \&lt;br /&gt;
       --genome ${ref} \&lt;br /&gt;
       --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
       --compress_input;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~35 min to complete with 10 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Consider complex ligation products (read pairs mapping to different fragments in the same molecule, i.e., multiple contacts) and multi‑mapping artifacts; TADbit focuses on valid pairs as operationally defined by the filters. Multi‑contact methods (e.g., Pore‑C, SPRITE) address this explicitly, but standard Hi‑C largely models binary contacts per ligation event. We can view it on the bam file in the next step.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Run filtering:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --tmpdb ${TMPDIR}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Change to workdir&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
# Summarize the run&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt;Check the “valid pairs” section of tadbit describe after filtering to get the exact count and percentage regarding the initial read pairs.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt;Because a read pair can be assigned to more than one category (e.g., a dangling end that is also a duplicate). Categories are not mutually exclusive, so percentages can overlap.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# First time we define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Choice of normalization (raw, ICE, Vanilla, decay)&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit normalize -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       --tmpdb ${TMPDIR} \&lt;br /&gt;
       --cpus 6 \&lt;br /&gt;
       --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
       --normalization ${norm} \&lt;br /&gt;
       --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
       --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~2 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⚠️ Run another version with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt; to compare later.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each job is assigned a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;. This helps retrieve results from specific runs (especially when testing parameters).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want, you can take a quick look at the different normalization strategies and extract your own conclusions:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Variables used for binning&lt;br /&gt;
&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
res=&amp;quot;100000&amp;quot;;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit bin \&lt;br /&gt;
       -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       -c ${chrom} \&lt;br /&gt;
       --plot \&lt;br /&gt;
       --norm &amp;quot;norm&amp;quot; \&lt;br /&gt;
       --format &amp;quot;png&amp;quot; \&lt;br /&gt;
       --cpus 6;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
[https://teaching.healthtech.dtu.dk/material/22126/2026/Raw_HiC.png Raw HiC matrix]&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
[https://teaching.healthtech.dtu.dk/material/22126/2026/Normal_HiC.png Normalized HiC matrix]&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=398</id>
		<title>Exercise and answers</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=398"/>
		<updated>2026-01-08T09:18:15Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt; &amp;lt;b&amp;gt;You will get notified something is missing, just accept&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
eval &amp;quot;$(/home/ctools/miniconda3/bin/conda shell.bash hook)&amp;quot;&lt;br /&gt;
conda activate &amp;quot;$HOME/envs/tadbit_course&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
# also a log folder for the scripts&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
# Filtered fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the template with your favorite editor, paste the following into the file, and save it.&lt;br /&gt;
For example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE;&lt;br /&gt;
cd ${data_dir};&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We can make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5–10 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A prepared script is also available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ~/3D_GENOMICS_COURSE/SCRIPTS;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch .;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While genome indexing runs, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the template and create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/01_fastp.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into the SBATCH script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
fastp \&lt;br /&gt;
    # Read raw fastq from course folders&lt;br /&gt;
    -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
    # Store the clean fastq version in your folder&lt;br /&gt;
    -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
    -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
    -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
    --detect_adapter_for_pe \&lt;br /&gt;
    # Trim first 5 bases (often lower quality)&lt;br /&gt;
    --trim_front1 5 \&lt;br /&gt;
    # Threads&lt;br /&gt;
    -w 10 \&lt;br /&gt;
    # Minimal read length (remove reads shorter than this after trimming)&lt;br /&gt;
    -l 30 \&lt;br /&gt;
    -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the HTML report to your local computer and open it in a browser:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
USER=&amp;quot;juanrod&amp;quot;&lt;br /&gt;
scp ${USER}@pupil1.healthtech.dtu.dk:/home/people/${USER}/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; It should be about ~96.4%. No massive adapter content or low quality sequences. After mapping we will inspect ligation/digestion patterns in more detail.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into your mapping script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for mapping&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;  # Double digestion (relevant for Arima/Phase Genomics)&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1;&lt;br /&gt;
&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --tmpdb ${TMPDIR} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
# &amp;gt;&amp;gt;&amp;gt; Just change the script to take that as a parameter.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; We are not using iterative mapping. Fragment-based mapping is the default in TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Cutting frequency differs between 4‑cutters and 6‑cutters and influences fragment size distribution, ligation probabilities, and contact resolution. Using two enzymes increases the diversity of ligation junctions. Compare with Micro‑C, which uses MNase digestion, so it cuts evenly through the genome.&amp;lt;/p&amp;gt;&lt;br /&gt;
[https://teaching.healthtech.dtu.dk/material/22126/2026/Fragment_histogram.pdf Fragment size histogram]&lt;br /&gt;
[https://teaching.healthtech.dtu.dk/material/22126/2026/ligation_deconvolution.png HiC Sequencing Quality and digestion - ligation deconvolution]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Fragment size histogram&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HiC sequencing quality and digestion/ligation deconvolution&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
ref=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# Keep only canonical chromosomes and compress map files after parsing&lt;br /&gt;
tadbit parse \&lt;br /&gt;
       --workdir ${wd} \&lt;br /&gt;
       --genome ${ref} \&lt;br /&gt;
       --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
       --compress_input;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~35 min to complete with 10 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Consider complex ligation products (read pairs mapping to different fragments in the same molecule, i.e., multiple contacts) and multi‑mapping artifacts; TADbit focuses on valid pairs as operationally defined by the filters. Multi‑contact methods (e.g., Pore‑C, SPRITE) address this explicitly, but standard Hi‑C largely models binary contacts per ligation event. We can view it on the bam file in the next step.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Run filtering:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --tmpdb ${TMPDIR}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Change to workdir&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
# Summarize the run&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt;Check the “valid pairs” section of tadbit describe after filtering to get the exact count and percentage regarding the initial read pairs.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt;Because a read pair can be assigned to more than one category (e.g., a dangling end that is also a duplicate). Categories are not mutually exclusive, so percentages can overlap.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# First time we define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Choice of normalization (raw, ICE, Vanilla, decay)&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit normalize -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       --tmpdb ${TMPDIR} \&lt;br /&gt;
       --cpus 6 \&lt;br /&gt;
       --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
       --normalization ${norm} \&lt;br /&gt;
       --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
       --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~2 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⚠️ Run another version with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt; to compare later.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each job is assigned a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;. This helps retrieve results from specific runs (especially when testing parameters).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want, you can take a quick look at the different normalization strategies and extract your own conclusions:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Variables used for binning&lt;br /&gt;
&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
res=&amp;quot;100000&amp;quot;;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit bin \&lt;br /&gt;
       -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       -c ${chrom} \&lt;br /&gt;
       --plot \&lt;br /&gt;
       --norm &amp;quot;norm&amp;quot; \&lt;br /&gt;
       --format &amp;quot;png&amp;quot; \&lt;br /&gt;
       --cpus 6;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=397</id>
		<title>Exercise and answers</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=397"/>
		<updated>2026-01-08T09:15:52Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt; &amp;lt;b&amp;gt;You will get notified something is missing, just accept&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
eval &amp;quot;$(/home/ctools/miniconda3/bin/conda shell.bash hook)&amp;quot;&lt;br /&gt;
conda activate &amp;quot;$HOME/envs/tadbit_course&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
# also a log folder for the scripts&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
# Filtered fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the template with your favorite editor, paste the following into the file, and save it.&lt;br /&gt;
For example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE;&lt;br /&gt;
cd ${data_dir};&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We can make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5–10 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A prepared script is also available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ~/3D_GENOMICS_COURSE/SCRIPTS;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch .;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While genome indexing runs, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the template and create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/01_fastp.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into the SBATCH script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
fastp \&lt;br /&gt;
    # Read raw fastq from course folders&lt;br /&gt;
    -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
    # Store the clean fastq version in your folder&lt;br /&gt;
    -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
    -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
    -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
    --detect_adapter_for_pe \&lt;br /&gt;
    # Trim first 5 bases (often lower quality)&lt;br /&gt;
    --trim_front1 5 \&lt;br /&gt;
    # Threads&lt;br /&gt;
    -w 10 \&lt;br /&gt;
    # Minimal read length (remove reads shorter than this after trimming)&lt;br /&gt;
    -l 30 \&lt;br /&gt;
    -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the HTML report to your local computer and open it in a browser:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
USER=&amp;quot;juanrod&amp;quot;&lt;br /&gt;
scp ${USER}@pupil1.healthtech.dtu.dk:/home/people/${USER}/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; It should be about ~96.4%. No massive adapter content or low quality sequences. After mapping we will inspect ligation/digestion patterns in more detail.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into your mapping script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for mapping&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;  # Double digestion (relevant for Arima/Phase Genomics)&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1;&lt;br /&gt;
&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --tmpdb ${TMPDIR} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
# &amp;gt;&amp;gt;&amp;gt; Just change the script to take that as a parameter.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; We are not using iterative mapping. Fragment-based mapping is the default in TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&lt;br /&gt;
Cutting frequency differs between 4‑cutters and 6‑cutters and influences fragment size distribution, ligation probabilities, and contact resolution. Using two enzymes increases the diversity of ligation junctions. Compare with Micro‑C, which uses MNase digestion, so it cuts evenly through the genome.&amp;lt;/p&amp;gt;&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Fragment_histogram.pdf Fragment size histogram])&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/ligation_deconvolution.png HiC Sequencing Quality and digestion - ligation deconvolution])&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Fragment size histogram&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HiC sequencing quality and digestion/ligation deconvolution&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
ref=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# Keep only canonical chromosomes and compress map files after parsing&lt;br /&gt;
tadbit parse \&lt;br /&gt;
       --workdir ${wd} \&lt;br /&gt;
       --genome ${ref} \&lt;br /&gt;
       --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
       --compress_input;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~35 min to complete with 10 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Run filtering:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --tmpdb ${TMPDIR}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Change to workdir&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
# Summarize the run&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# First time we define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Choice of normalization (raw, ICE, Vanilla, decay)&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit normalize -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       --tmpdb ${TMPDIR} \&lt;br /&gt;
       --cpus 6 \&lt;br /&gt;
       --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
       --normalization ${norm} \&lt;br /&gt;
       --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
       --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~2 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⚠️ Run another version with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt; to compare later.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each job is assigned a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;. This helps retrieve results from specific runs (especially when testing parameters).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want, you can take a quick look at the different normalization strategies and extract your own conclusions:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Variables used for binning&lt;br /&gt;
&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
res=&amp;quot;100000&amp;quot;;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit bin \&lt;br /&gt;
       -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       -c ${chrom} \&lt;br /&gt;
       --plot \&lt;br /&gt;
       --norm &amp;quot;norm&amp;quot; \&lt;br /&gt;
       --format &amp;quot;png&amp;quot; \&lt;br /&gt;
       --cpus 6;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=396</id>
		<title>Denovo exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=396"/>
		<updated>2026-01-08T09:12:47Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to the directory you just created.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise we will perform a &amp;lt;b&amp;gt;de novo assembly&amp;lt;/b&amp;gt; of Illumina paired-end reads. The data is from a &amp;lt;i&amp;gt;Vibrio cholerae&amp;lt;/i&amp;gt; strain isolated in Nepal. You will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run FastQC and perform adapter/quality trimming (optional recap of pre-processing).&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Count k-mers and estimate genome size.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Correct reads using Musket.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Determine insert size of paired-end reads.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run de novo assembly using MEGAHIT.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Calculate assembly statistics.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Plot coverage and length histograms of the assembly.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Evaluate the assembly quality.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Visualize the assembly using Circoletto.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;(Bonus) Try assembling the genome with SPAdes.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Annotation of a prokaryotic genome.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;FastQC and trimming&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Make sure you are in the &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt; directory you created. You can double-check with:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pwd&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the sequencing data:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/* .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run FastQC on the reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing FastQC HTML reports:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the FastQC HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_1_sequence_fastqc.html .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_2_sequence_fastqc.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;There are several issues with this dataset (you do not need to study the report in detail now). We will clean it up first. Let’s identify the quality encoding:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_detect_fq.sh Vchol-001_6_1_sequence.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1. Which quality encoding format is used?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Trim the reads using AdapterRemoval. The most frequent adapter/primer sequences are already included below. We use a minimum read length of 40 nt, trim to quality 20, and specify quality base 64. The &amp;lt;code&amp;gt;--basename&amp;lt;/code&amp;gt; option defines the output prefix and &amp;lt;code&amp;gt;--gzip&amp;lt;/code&amp;gt; compresses the output.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/adapterremoval-2.3.4/build/AdapterRemoval \&lt;br /&gt;
  --file1 Vchol-001_6_1_sequence.txt.gz \&lt;br /&gt;
  --file2 Vchol-001_6_2_sequence.txt.gz \&lt;br /&gt;
  --adapter1 GATCGGAAGAGCACACGTCTGAACTCCAGTCACATCACGATATCGTATGC \&lt;br /&gt;
  --adapter2 GATCGGAAGAGCGTCGTGTAGGGAAAGAGGGTAGATCTCGGTGGTCGCCG \&lt;br /&gt;
  --qualitybase 64 \&lt;br /&gt;
  --basename Vchol-001_6 \&lt;br /&gt;
  --gzip \&lt;br /&gt;
  --trimqualities \&lt;br /&gt;
  --minquality 20 \&lt;br /&gt;
  --minlength 40&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When it finishes, inspect &amp;lt;code&amp;gt;Vchol-001_6.settings&amp;lt;/code&amp;gt; for trimming statistics (how many reads were trimmed, discarded, etc.).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1A. The output includes &amp;lt;code&amp;gt;discarded.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair1.truncated.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair2.truncated.gz&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;singleton.truncated.gz&amp;lt;/code&amp;gt;. What types of reads does each file contain? (Tip: check the AdapterRemoval documentation.)&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, compute basic read stats (average read length, min/max length, number of reads, total bases) for the trimmed paired reads. Note down the average read length and total number of bases:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair1.truncated.gz&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair2.truncated.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Genome size estimation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will count k-mers in the data. A k-mer is simply a DNA word of length k. We use &amp;lt;b&amp;gt;jellyfish&amp;lt;/b&amp;gt; to count 15-mers. We combine counts from forward and reverse-complement strands and then create a histogram. (This may take some time to run so could be good time to practice using &amp;quot;screen&amp;quot;)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Manual: [http://www.cbcb.umd.edu/software/jellyfish/jellyfish-manual.html jellyfish]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip -dc Vchol-001_6.pair*.truncated.gz \&lt;br /&gt;
  | /home/ctools/jellyfish-2.3.1/bin/jellyfish count -t 2 -m 15 -s 1000000000 -o Vchol-001 -C /dev/fd/0&lt;br /&gt;
&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish histo Vchol-001 &amp;gt; Vchol-001.histo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;Vchol-001.histo&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;Vchol-001.histo.pdf&amp;quot;)&lt;br /&gt;
barplot(dat[,2],&lt;br /&gt;
        xlim = c(0,150),&lt;br /&gt;
        ylim = c(0,5e5),&lt;br /&gt;
        ylab = &amp;quot;No of kmers&amp;quot;,&lt;br /&gt;
        xlab = &amp;quot;Counts of a k-mer&amp;quot;,&lt;br /&gt;
        names.arg = dat[,1],&lt;br /&gt;
        cex.names = 0.8)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the pdf files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/Vchol-001.histo.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The plot shows:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;x-axis: how many times a k-mer occurs (its count)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;y-axis: number of distinct k-mers with that count&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;K-mers that occur only a few times are typically due to sequencing errors. K-mers forming the main peak (higher counts) are likely “real” and can be used for error correction and genome size estimation.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2. Where is the k-mer coverage peak (approximately)?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We can estimate genome size using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
N = (M * L) / (L - K + 1)&lt;br /&gt;
Genome_size = T / N&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;N&amp;lt;/b&amp;gt; = depth (coverage)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;M&amp;lt;/b&amp;gt; = k-mer peak (from the histogram)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;K&amp;lt;/b&amp;gt; = k-mer size (here: 15)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;L&amp;lt;/b&amp;gt; = average read length (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;T&amp;lt;/b&amp;gt; = total number of bases (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute the estimated genome size and compare with the known &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome (~4 Mb). You should be within roughly ±10%.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3. What is your estimated genome size?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Error correction&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will correct errors in the reads using &amp;lt;b&amp;gt;Musket&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Musket: [http://musket.sourceforge.net/homepage.htm Musket]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, get the number of distinct k-mers (needed for memory allocation in Musket):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish stats Vchol-001&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the reported number of distinct k-mers (here an example: &amp;lt;code&amp;gt;8423098&amp;lt;/code&amp;gt;) in the Musket command:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/musket-1.1/musket -k 15 8423098 -p 1 -omulti Vchol-001_6.cor -inorder \&lt;br /&gt;
  Vchol-001_6.pair1.truncated.gz Vchol-001_6.pair2.truncated.gz -zlib 1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output files are named &amp;lt;code&amp;gt;Vchol-001_6.cor.0&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;Vchol-001_6.cor.1&amp;lt;/code&amp;gt;. Rename them:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mv Vchol-001_6.cor.0 Vchol-001_6.pair1.cor.truncated.fq.gz&lt;br /&gt;
mv Vchol-001_6.cor.1 Vchol-001_6.pair2.cor.truncated.fq.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;If this takes too long, you can copy precomputed corrected reads:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/corrected/Vchol-001_6.pair*.cor.truncated.fq.gz .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;&amp;lt;i&amp;gt;De novo&amp;lt;/i&amp;gt; assembly with MEGAHIT&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now assemble the corrected reads using &amp;lt;b&amp;gt;MEGAHIT&amp;lt;/b&amp;gt; (a de Bruijn graph assembler). K-mer size is critical: MEGAHIT can test multiple k-mers by default, but here we start with a fixed k-mer size of 35.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, set the number of threads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run MEGAHIT with k=35:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list 35 \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o 35&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When finished, you should have &amp;lt;code&amp;gt;35/final.contigs.fa&amp;lt;/code&amp;gt;. Compress it:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip 35/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To estimate insert size, we will map a subset of reads back to the assembly (similar to the alignment exercise). We’ll subsample the first 100,000 read pairs (400,000 lines per FASTQ):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat Vchol-001_6.pair1.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_1.fastq&lt;br /&gt;
zcat Vchol-001_6.pair2.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_2.fastq&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the assembly and map:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bwa index 35/final.contigs.fa.gz&lt;br /&gt;
&lt;br /&gt;
bwa mem 35/final.contigs.fa.gz Vchol_sample_1.fastq Vchol_sample_2.fastq \&lt;br /&gt;
  | samtools view -Sb - &amp;gt; Vchol_35bp.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract insert sizes (TLEN field, column 9):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view Vchol_35bp.bam | cut -f9 &amp;gt; initial.insertsizes.txt&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
a   = read.table(&amp;quot;initial.insertsizes.txt&amp;quot;)&lt;br /&gt;
a.v = a[a[,1] &amp;gt; 0, 1]&lt;br /&gt;
mn  = quantile(a.v, seq(0,1,0.05))[4]&lt;br /&gt;
mx  = quantile(a.v, seq(0,1,0.05))[18]&lt;br /&gt;
mean(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])   # mean insert size&lt;br /&gt;
sd(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])     # standard deviation&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4. What are the mean insert size and standard deviation of the library?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we will explore different k-mer sizes. Each student chooses a different k-mer from this Google sheet:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://docs.google.com/spreadsheets/d/1trUMlSwNLoNW67D-OkgA93iOQRp2iioyJSBYyW30P4U/edit?usp=sharing Google sheet for k-mer assignment]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Write your name next to the k-mer you select, then run MEGAHIT with that k-mer, replacing &amp;lt;code&amp;gt;[KMER]&amp;lt;/code&amp;gt; below:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list [KMER] \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o [KMER]&lt;br /&gt;
&lt;br /&gt;
gzip [KMER]/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute assembly statistics using &amp;lt;code&amp;gt;QUAST&amp;lt;/code&amp;gt; - note: quast does not consider contigs smaller than 500bp:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
 [KMER]/final.contigs.fa.gz \&lt;br /&gt;
 --threads 1 \&lt;br /&gt;
 -o [KMER]/quast&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the file &amp;lt;code&amp;gt;[KMER]/quast/report.txt&amp;lt;/code&amp;gt; (or &amp;lt;code&amp;gt;report.tsv&amp;lt;/code&amp;gt;) and&lt;br /&gt;
record the following values in the Google sheet for your k-mer:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Number of contigs (&amp;amp;ge; 500 bp)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Total assembly length&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Largest contig&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;N50&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;As a class, compare results across k-mer sizes and discuss which k-mer produces&lt;br /&gt;
the most reasonable assembly and why.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the best assembly to your folder, or use a precomputed multi-k assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.fa.gz .&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.stats .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5. How does the N50 of the best assembly (multi-k or default) compare to the N50 from the fixed-k assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6. How does the longest contig length compare between fixed-k and multi-k/default assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Coverage of the assembly&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now calculate per-contig coverage and lengths, and visualize them in R.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat default_final.contigs.fa.gz | /home/ctools/bin/fastx_megahit.sh --i /dev/stdin &amp;gt; default_finalt.cov&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(plotrix)&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;default_finalt.cov&amp;quot;, sep = &amp;quot;\t&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
## ---- Coverage plots (2 panels) ----&lt;br /&gt;
pdf(&amp;quot;best.coverage.pdf&amp;quot;, width = 10, height = 5)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
&lt;br /&gt;
weighted.hist(w = dat[,2],&lt;br /&gt;
              x = dat[,1],&lt;br /&gt;
              breaks = seq(0, 100, 1),&lt;br /&gt;
              main = &amp;quot;Weighted coverage&amp;quot;,&lt;br /&gt;
              xlab = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
hist(dat[,1],&lt;br /&gt;
     xlim   = c(0, 100),&lt;br /&gt;
     breaks = seq(0, 1000, 1),&lt;br /&gt;
     main   = &amp;quot;Raw coverage&amp;quot;,&lt;br /&gt;
     xlab   = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&lt;br /&gt;
## ---- Scaffold lengths (1 panel) ----&lt;br /&gt;
pdf(&amp;quot;scaffold.lengths.pdf&amp;quot;, width = 7, height = 5)&lt;br /&gt;
par(mfrow = c(1, 1))&lt;br /&gt;
&lt;br /&gt;
barplot(rev(sort(dat[,2])),&lt;br /&gt;
        xlab = &amp;quot;# Scaffold&amp;quot;,&lt;br /&gt;
        ylab = &amp;quot;Length&amp;quot;,&lt;br /&gt;
        main = &amp;quot;Scaffold Lengths&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;View the plots:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing the PDF files:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the PDF files directly from the&lt;br /&gt;
left-hand file panel.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the PDF files to your&lt;br /&gt;
local computer and open them with any PDF viewer. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/best.coverage.pdf .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/scaffold.lengths.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The left plot shows length-weighted coverage: long contigs contribute more to the histogram. The right plot shows the raw distribution of contig coverage. Typically, most of the assembly will cluster around the expected coverage (e.g. ~60–90×), and shorter contigs will have more variable coverage. The scaffold length plot shows that most of the assembled bases are in relatively long scaffolds.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7. Why might some short contigs have much &amp;lt;i&amp;gt;higher&amp;lt;/i&amp;gt; coverage than the main assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8. Why might some short contigs have much &amp;lt;i&amp;gt;lower&amp;lt;/i&amp;gt; coverage than the main assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Assembly evaluation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use &amp;lt;b&amp;gt;QUAST&amp;lt;/b&amp;gt; to evaluate the assembly using various reference-based metrics.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;QUAST: [https://quast.sourceforge.net/quast quast]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run QUAST against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
  default_final.contigs.fa.gz \&lt;br /&gt;
  --threads 1 \&lt;br /&gt;
  -R /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/quast_results/latest/report.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9. The report lists several misassemblies. Can we always fully trust these “misassembly” calls? Why or why not?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Visualization using Circoletto&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will visualize the assembly against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference using Circoletto.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, filter out contigs shorter than 500 bp:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_filterfasta.sh default_final.contigs.fa.gz 500 &amp;gt; default_final.contigs_filtered_500.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;On your local machine, open a browser and go to:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://bat.infspire.org/circoletto/ Circoletto]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the filtered assembly in a text editor on the server, for example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit default_final.contigs_filtered_500.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste the FASTA content into the &amp;lt;b&amp;gt;“Query fasta”&amp;lt;/b&amp;gt; box on the Circoletto page.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then open the reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste this into the &amp;lt;b&amp;gt;“Subject fasta”&amp;lt;/b&amp;gt; box.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In the “Output” section, select &amp;lt;b&amp;gt;“ONLY show the best hit per query”&amp;lt;/b&amp;gt;, then click &amp;lt;b&amp;gt;Submit to Circoletto&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If Circoletto does not work, you can use this precomputed image:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/denovo/circoletto_results/cl0011524231.blasted.png&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You should see the two &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; chromosomes on the left (labelled with “gi|…”) and the alignment of your contigs to these chromosomes. Colours represent BLAST bitscores (red = high confidence, black = low).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10. Does your assembled genome appear broadly similar to the reference genome?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11. Are there contigs/scaffolds that do not map, or only partially map, to the reference?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12. On chromosome 2 (the smaller chromosome), there may be a region with many short, low-confidence hits. What might this region represent? Hint: see the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome paper and search for “V. cholerae integron island”: [https://www.nature.com/articles/35020000 V. cholerae genome paper]&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Try to assemble the genome using SPAdes (bonus)&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Different assemblers can perform very differently. &amp;lt;b&amp;gt;SPAdes&amp;lt;/b&amp;gt; is widely used and generally performs well. It performs error correction and uses multiple k-mer sizes internally.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;SPAdes: [https://ablab.github.io/spades/ SPAdes]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Check the help output:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/SPAdes-4.2.0-Linux/bin/spades.py -h&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; A full SPAdes run may take ~45 minutes. You can use the precomputed SPAdes assembly instead and compare to MEGAHIT using QUAST and Assemblathon stats.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Link to the SPAdes assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/denovo/vchol/spades/spades.fasta spades.fasta&lt;br /&gt;
# from here you can compute stats and run QUAST&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Annotation of a prokaryotic genome&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will annotate genes in &amp;lt;code&amp;gt;ecoli_pacbio.contigs.fasta&amp;lt;/code&amp;gt; using &amp;lt;b&amp;gt;prodigal&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Prodigal: [https://bmcbioinformatics.biomedcentral.com/articles/10.1186/1471-2105-11-119 prodigal]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output will be a GFF file with gene coordinates and a FASTA file with predicted proteins:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
prodigal \&lt;br /&gt;
  -f gff \&lt;br /&gt;
  -i [input genome in fasta] \&lt;br /&gt;
  -a [output proteins in fasta] \&lt;br /&gt;
  -o [output annotations in gff]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;GFF format: [https://www.ensembl.org/info/website/upload/gff.html GFF format description]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, index the protein FASTA file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract the protein sequence for gene ID &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa tig00000001_4582&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use BLASTP against the nr database:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://blast.ncbi.nlm.nih.gov/Blast.cgi?PROGRAM=blastp&amp;amp;PAGE_TYPE=BlastSearch&amp;amp;LINK_LOC=blasthome BLAST for proteins]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Paste the sequence and run BLASTP.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14. Which protein (function) does &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt; correspond to?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please find answers here: [[Denovo_solution|Denovo_solution]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=393</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=393"/>
		<updated>2026-01-08T08:53:52Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2026/dtu_adna_2026_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[ Microbial_genomics_exercise ]]) ([[ solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Questions]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercises]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Metabarcoding Exercise]]) ([[Metabarcoding Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024.pdf Test 2025])([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024_withA.pdf answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=392</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=392"/>
		<updated>2026-01-08T08:41:10Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2025/dtu_adna_2025_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[ Microbial_genomics_exercise ]]) ([[ solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Questions]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercises]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Metabarcoding Exercise]]) ([[Metabarcoding Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024.pdf Test 2025])([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024_withA.pdf answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=391</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=391"/>
		<updated>2026-01-08T08:34:25Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30pm-9:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2025/dtu_adna_2025_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[ Microbial_genomics_exercise ]]) ([[ solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Questions]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercises]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Metabarcoding Exercise]]) ([[Metabarcoding Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024.pdf Test 2025])([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024_withA.pdf answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_answers_part_1&amp;diff=388</id>
		<title>SNP calling exercise answers part 1</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_answers_part_1&amp;diff=388"/>
		<updated>2026-01-07T14:55:07Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Answers&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q1&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First index the gVCF:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix -f -p vcf NA24694.gvcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then run HaplotypeCaller:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk --java-options &amp;quot;-Xmx10g&amp;quot; HaplotypeCaller \&lt;br /&gt;
  -R /home/databases/references/human/GRCh38_full_analysis_set_plus_decoy_hla.fa \&lt;br /&gt;
  -I /home/projects/22126_NGS/exercises/snp_calling/NA24694.bam \&lt;br /&gt;
  -L chr20 \&lt;br /&gt;
  -O NA24694.gvcf.gz \&lt;br /&gt;
  --dbsnp /home/databases/databases/GRCh38/Homo_sapiens_assembly38.dbsnp138.vcf.gz \&lt;br /&gt;
  -ERC GVCF&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then genotype the gVCF:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk GenotypeGVCFs \&lt;br /&gt;
  -R /home/databases/references/human/GRCh38_full_analysis_set_plus_decoy_hla.fa \&lt;br /&gt;
  -V NA24694.gvcf.gz \&lt;br /&gt;
  -L chr20 \&lt;br /&gt;
  --dbsnp /home/databases/databases/GRCh38/Homo_sapiens_assembly38.dbsnp138.vcf.gz \&lt;br /&gt;
  -O NA24694.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Finally, count SNPs using &amp;lt;code&amp;gt;bcftools stats&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools stats NA24694.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You should see something like:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SN    0    number of SNPs:    75684&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; There are &amp;lt;b&amp;gt;75,684 SNPs&amp;lt;/b&amp;gt; on chromosome 20 in this sample.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q2&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the VCF if not already indexed:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix -p vcf NA24694.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then query the 1 Mb region:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix NA24694.vcf.gz chr20:32000000-33000000 | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; &amp;lt;b&amp;gt;1290 variant sites&amp;lt;/b&amp;gt; in this region (all variant types).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q3&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Count only SNPs (exclude indels and multi-allelic sites):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -H --type snps NA24694.vcf.gz chr20:32000000-33000000 | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;or equivalently:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix -h NA24694.vcf.gz chr20:32000000-33000000 \&lt;br /&gt;
  | /home/ctools/bcftools-1.23/bcftools view -H --type snps - \&lt;br /&gt;
  | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; &amp;lt;b&amp;gt;956 SNPs&amp;lt;/b&amp;gt; in the region.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q4&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Variant at chr20:32011209&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix NA24694.vcf.gz chr20:32011209-32011209&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20  32011209  rs147652161  G  A  264.64  .  &lt;br /&gt;
AC=1;AF=0.500;AN=2;BaseQRankSum=-0.301;DB;DP=24;FS=3.949;MQ=60.00;QD=11.03;SOR=0.552  &lt;br /&gt;
GT:AD:DP:GQ:PL  0/1:15,9:24:99:272,0,533&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Interpretation&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Genotype: &amp;lt;b&amp;gt;0/1&amp;lt;/b&amp;gt; (heterozygous G/A)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Allele depth (AD): &amp;lt;b&amp;gt;15 G&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;9 A&amp;lt;/b&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Depth (DP): &amp;lt;b&amp;gt;24&amp;lt;/b&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Genotype quality (GQ): &amp;lt;b&amp;gt;99&amp;lt;/b&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Genotype likelihoods (PL): &amp;lt;b&amp;gt;272,0,533&amp;lt;/b&amp;gt; (het most likely)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Variant at chr20:32044279&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix NA24694.vcf.gz chr20:32044279-32044279&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20  32044279  rs4525768  C  T  799.06  .  &lt;br /&gt;
AC=2;AF=1.00;AN=2;DB;DP=21;MQ=60.00;QD=28.99  &lt;br /&gt;
GT:AD:DP:GQ:PL  1/1:0,21:21:63:813,63,0&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Interpretation&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Genotype: &amp;lt;b&amp;gt;1/1&amp;lt;/b&amp;gt; (homozygous T/T)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Allele depth (AD): &amp;lt;b&amp;gt;0 C&amp;lt;/b&amp;gt;, &amp;lt;b&amp;gt;21 T&amp;lt;/b&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Depth (DP): &amp;lt;b&amp;gt;21&amp;lt;/b&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Genotype quality (GQ): &amp;lt;b&amp;gt;63&amp;lt;/b&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Genotype likelihoods (PL): &amp;lt;b&amp;gt;813,63,0&amp;lt;/b&amp;gt; (homozygous alt most likely)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q5&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Higher-quality heterozygous SNP&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20 32974911 rs6088051 A G ... GT:AD:DP:GQ:PL  0/1:8,13:21:99:411,0,247&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Lower-quality heterozygous SNP&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20 64291638 rs369221086 C T ... GT:AD:DP:GQ:PL  0/1:4,2:6:38:38,0,114&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Why?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;The first site has &amp;lt;b&amp;gt;much higher depth&amp;lt;/b&amp;gt; (21× vs 6×)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Allele balance is more reasonable: 8/13 vs 4/2&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;The genotype quality (GQ) is much higher: &amp;lt;b&amp;gt;99 vs 38&amp;lt;/b&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Overall likelihoods strongly support the correct genotype&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Conclusion:&amp;lt;/b&amp;gt; More data ⇒ higher confidence.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q6&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Count SNPs with no dbSNP ID (column 3 = &amp;lt;code&amp;gt;.&amp;lt;/code&amp;gt;):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -H --types snps NA24694.vcf.gz chr20:32000000-33000000 \&lt;br /&gt;
  | cut -f 3 \&lt;br /&gt;
  | grep -v rs \&lt;br /&gt;
  | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;or equivalently:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -H --types snps NA24694.vcf.gz chr20:32000000-33000000 \&lt;br /&gt;
  | cut -f 3 \&lt;br /&gt;
  | grep &amp;quot;\.&amp;quot; \&lt;br /&gt;
  | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; &amp;lt;b&amp;gt;17 novel SNPs&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q7&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You found:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;956 total SNPs&amp;lt;/b&amp;gt; in the region (Q3)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;17 novel SNPs&amp;lt;/b&amp;gt; (Q6)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Only ~1.8% of SNPs are novel.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This is expected because:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Han Chinese individuals are extremely well represented in dbSNP and 1000 Genomes.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;dbSNP contains &amp;gt;100 million known variants, so most common variation is already catalogued.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Novel variants tend to be rare or extremely rare.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Conclusion:&amp;lt;/b&amp;gt; The number of novel variants is small and biologically reasonable.&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_answers_part_2&amp;diff=387</id>
		<title>SNP calling exercise answers part 2</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_answers_part_2&amp;diff=387"/>
		<updated>2026-01-07T13:24:01Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Answers&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q1 — How many sites were filtered out?&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;After running:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk VariantFiltration \&lt;br /&gt;
   -V NA24694.vcf.gz \&lt;br /&gt;
   -O NA24694_hf.vcf.gz \&lt;br /&gt;
   -filter &amp;quot;DP &amp;lt; 10.0&amp;quot;   --filter-name &amp;quot;DP&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;QUAL &amp;lt; 30.0&amp;quot; --filter-name &amp;quot;QUAL30&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;SOR &amp;gt; 3.0&amp;quot;   --filter-name &amp;quot;SOR3&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;FS &amp;gt; 60.0&amp;quot;   --filter-name &amp;quot;FS60&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;MQ &amp;lt; 40.0&amp;quot;   --filter-name &amp;quot;MQ40&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Count all filtered variants (non-PASS):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -H NA24694_hf.vcf.gz | grep -v PASS | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;4005 sites&amp;lt;/b&amp;gt; were filtered out (all variant types).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Count only SNPs filtered out:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -H --type=snps NA24694_hf.vcf.gz | grep -v PASS | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;2630 SNPs&amp;lt;/b&amp;gt; were filtered out.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q2 — Which filter removed the most sites?&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;One approach:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -H NA24694_hf.vcf.gz \&lt;br /&gt;
 | grep -v PASS \&lt;br /&gt;
 | cut -f7 \&lt;br /&gt;
 | sort \&lt;br /&gt;
 | uniq -c \&lt;br /&gt;
 | sort -n&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This produces:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
      5 FS60;SOR3&lt;br /&gt;
     30 DP;MQ40;SOR3&lt;br /&gt;
     74 MQ40;SOR3&lt;br /&gt;
    158 DP;SOR3&lt;br /&gt;
    197 DP;MQ40&lt;br /&gt;
    390 MQ40&lt;br /&gt;
   1340 SOR3&lt;br /&gt;
   1811 DP&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Depth filter (DP)&amp;lt;/b&amp;gt; removed the most sites, followed by &amp;lt;b&amp;gt;SOR&amp;lt;/b&amp;gt; (strand bias) and &amp;lt;b&amp;gt;MQ&amp;lt;/b&amp;gt; (mapping quality).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q3 — How many sites remain after applying the mappability filter?&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First extract sites that passed all hard filters:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -f PASS NA24694_hf.vcf.gz \&lt;br /&gt;
  | /home/ctools/htslib-1.20/bgzip -c &amp;gt; NA24694_hf_pass.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Count variants that passed all filters:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -H NA24694_hf_pass.vcf.gz | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;88,594 total variants&amp;lt;/b&amp;gt; (SNPs + indels + multi-allelic sites).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Now retain only variants in high-mappability regions:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bedtools intersect -header \&lt;br /&gt;
  -a NA24694_hf_pass.vcf.gz \&lt;br /&gt;
  -b /home/databases/databases/GRCh38/filter99.bed.gz \&lt;br /&gt;
 | /home/ctools/htslib-1.20/bgzip -c &amp;gt; NA24694_hf_map99.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Count remaining sites:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view -H NA24694_hf_map99.vcf.gz | wc -l&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;51,624 variants&amp;lt;/b&amp;gt; remain after mappability filtering.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q4 — Most common genomic category (snpEff)&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run snpEff:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
java -jar /home/ctools/snpEff/snpEff.jar eff \&lt;br /&gt;
   -dataDir /home/databases/databases/snpEff/ \&lt;br /&gt;
   -htmlStats NA24694_hf.html \&lt;br /&gt;
   GRCh38.99 \&lt;br /&gt;
   NA24694_hf.vcf.gz \&lt;br /&gt;
 | /home/ctools/htslib-1.20/bgzip -c &amp;gt; NA24694_hf_ann.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;From the snpEff HTML output:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Intron variants = 64.368%&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; Most variants fall in &amp;lt;b&amp;gt;intronic regions&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Q5 — Variants that cause a codon change&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;From the snpEff HTML report:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;MISSENSE = 584 variants (44.242%)&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Answer:&amp;lt;/b&amp;gt; &amp;lt;b&amp;gt;584 missense mutations&amp;lt;/b&amp;gt; are predicted to change a codon and alter the protein sequence.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;End of Answers&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Rnaseq_exercise&amp;diff=383</id>
		<title>Rnaseq exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Rnaseq_exercise&amp;diff=383"/>
		<updated>2026-01-07T11:48:34Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-content has-page-title&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;overview-and-background&amp;quot; class=&amp;quot;section level1&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h1&amp;gt;Overview and background&amp;lt;/h1&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;groups&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Groups&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Please get into groups of 2-3. We don’t have enough computational power for all of you working alone. Please let the instructors know if you need help finding a group.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;assignment-notes&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Assignment notes&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;While some questions might seem hard we naturally don’t ask questions/tasks which you have not been given the tools to solve in this assignment - so if you are stuck try thinking about what you have already learned before asking an instructor.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;assignment-overview&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Assignment overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;In this assignment you are going to analyze RNA-sequencing data from real cancer patients to analyze the importance of alternative splicing in a clinical context&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;biological-background&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Biological background&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Today you will be working with colorectal cancers - specifically Colon Adenocarcinoma (often abbreviated COAD). It is a cancer of the colon that is very frequent. The lifetime risk of developing&lt;br /&gt;
colorectal cancer is ~4% for both males and females. That means COAD represents ~10% of all cancers and results in the death of hundreds of thousands of people each year! (More info on COAD can be found on [https://en.wikipedia.org/wiki/Colorectal_cancer Wikipedia].&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;One important aspect of cancer is that tumors from different patients are extremely different even when they originate from the same tissue (more info on tumor heterogeneity [https://en.wikipedia.org/wiki/Tumour_heterogeneity here]). To improve treatment and prognosis we therefore try to classify COAD into cancer subtypes (a simple form of precision medicine). We currently think there are 5 subtypes (see [https://www.cell.com/cancer-cell/pdf/S1535-6108(18)30114-4.pdf Liu &#039;&#039;et al.&#039;&#039;]) and today you will be working with CIN and GS. CIN is an abbreviation for Chromosomal INstable and GS means genome stable. More on that later.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To help us understand COAD subtypes you will today compare these to healthy adjacent tissue. For all samples a biopsy was taken and bulk RNA-seq performed. Low-quality samples have been removed.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;bioinformatic-background&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Bioinformatic background&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;For background on transcriptomics and splicing please refer to today’s slides. The data you are working with is a randomly selected a subset of the TCGA COAD data (google TCGA if you want to know more). The data was quantified with Kallisto against the human transcriptome.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Today you will be using the &#039;pairedGSEA&#039; R package we developed. This package is specifically designed to make it easy to do the following analysis:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol style=&amp;quot;list-style-type: decimal&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Differential gene expression (aka DGE) via DESeq(2)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Differential gene usage (differential splicing) (aka DGU)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;gene-set over-representation analysis (ORA) on DGU and DGE&lt;br /&gt;
results&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;While at each step facilitating easy comparison of DGE and DGU.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;hr /&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;assignment&amp;quot; class=&amp;quot;section level1&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h1&amp;gt;Assignment&amp;lt;/h1&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-1-determine-which-cancer-to-work-with&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 1: Determine which cancer to work with&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Determine which cancer type you will work with:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;If your birthday is within the first 6 months of the year (January-June) you will work with &amp;lt;strong&amp;gt;CIN&amp;lt;/strong&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;If your birthday is within the last 6 months of the year (July-December) you will work with &amp;lt;strong&amp;gt;GS&amp;lt;/strong&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-2-set-up-enviroment&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 2: Set up enviroment&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Log into the server as you usually do except this time you have to use the &#039;-X&#039; option. That means using:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ssh -X username@pupil1.healthtech.dtu.dk&amp;lt;/pre&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Make a directory for this exercise and move into it&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir transcriptomics_exercise&lt;br /&gt;
cd transcriptomics_exercise&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the exercise data of your cancer subtype to your folder&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
### for CIN subtype:&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/transcriptomics/coad_iso_subset_cin.Rdata .&lt;br /&gt;
&lt;br /&gt;
### For GS subtype:&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/transcriptomics/coad_iso_subset_gs.Rdata .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-3-start-r-session-and-enviroment&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 3: Start R session and enviroment&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;To start an R session in your terminal typing (or copy/pasting)&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/opt/R-4.4.2_22140/bin/R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;And load the library we need by typing&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(pairedGSEA)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This loads the functionality of the “pairedGSEA” R package.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-4-load-and-inspect-data&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 4: Load and inspect data&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Load the assignment data into your R session:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
### for CIN subtype:&lt;br /&gt;
load(&amp;amp;#39;coad_iso_subset_cin.Rdata&amp;amp;#39;)&lt;br /&gt;
&lt;br /&gt;
### For GS subtype:&lt;br /&gt;
load(&amp;amp;#39;coad_iso_subset_gs.Rdata&amp;amp;#39;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;This will give you two data objects in your R session:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol style=&amp;quot;list-style-type: decimal&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;A count matrix&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;A matrix with meta information about each sample in the count matrix.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;A list of gene_sets that you should use for your ORA analysis (step 7).&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;All objects can be directly used by the &#039;pairedGSEA&#039;&lt;br /&gt;
package - no need to do any data modifications.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Use the following functions to take a look at the data:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
### List objects in an R session&lt;br /&gt;
ls()&lt;br /&gt;
&lt;br /&gt;
### Inspect the first lines of the object&lt;br /&gt;
head( &amp;amp;lt;object_name&amp;amp;gt; )&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: Which object contains what data?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-5-run-differential-analysis&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 5: Run differential analysis&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Next you will need to use the &#039;pairedGSEA&#039; package and&lt;br /&gt;
here a bit of self-study is needed. &amp;lt;strong&amp;gt;Importantly&amp;lt;/strong&amp;gt; you&lt;br /&gt;
should only run this analysis once per group - else we don’t have&lt;br /&gt;
enough computational power. You can download the&lt;br /&gt;
&#039;pairedGSEA&#039; vignette (short document showing how to use it)&lt;br /&gt;
&amp;lt;a href=&amp;quot;https://www.dropbox.com/s/oalth29pxulffec/pairedGSEA.html?dl=1&amp;quot;&amp;gt;here&amp;lt;/a&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Hints:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol style=&amp;quot;list-style-type: decimal&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;After reading the introduction you can skip to the&lt;br /&gt;
&#039;3.3 Running the analysis&#039; section.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;For now you only need to use &#039;paired_diff()&#039; as that&lt;br /&gt;
makes both differential analyses (both DGE and DGU).&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;There is no need to use the “store_results” option&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: This will take a while to run (~10 min).&lt;br /&gt;
In the mean time take a closer look at the Liu &amp;lt;em&amp;gt;et al.&amp;lt;/em&amp;gt; paper&lt;br /&gt;
(see above) and summarise what the difference between the CIN and GS&lt;br /&gt;
COAD subtypes are.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-6-inspect-diffrential-result&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 6: Inspect diffrential result&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: Look at the first 10 lines of the result&lt;br /&gt;
file. Which gene is most significant (smallest p-value) for the DGE and&lt;br /&gt;
DGU analysis (respectively DESeq2 and DEXSeq)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The following code &amp;lt;em&amp;gt;example&amp;lt;/em&amp;gt; counts how many significantly&lt;br /&gt;
differentially expressed genes are found:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sum( gi_diff_results$padj_deseq &amp;amp;lt; 0.05, na.rm = T )&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: Modify the R code above to count how many&lt;br /&gt;
genes are DGE and DGU.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: Use the &#039;nrow()&#039; function to&lt;br /&gt;
calculate the fraction of genes that are DGE and DGU.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Now we are ready to do the gene-set enrichment analysis.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-7-run-gene-set-enrichment-analysis&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 7: Run Gene-Set Enrichment Analysis&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Use the vignette to help you use &#039;pairedGSEA&#039; to run GSEA on both DGE and DGU results (see the vignette section 4: “Over-Representation Analysis”). You should use the &#039;gene_set_list&#039; object you have already loaded into R instead of using the &#039;prepare_msigdb()&#039; function.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Note: There is (again) no need to store the intermediary results.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-8-inspect-ora-result&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 8: Inspect ORA result&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;What you have been analyzing so far is a subset of the entire dataset&lt;br /&gt;
(since the runtime else would have been 3-4x longer). To enable a more&lt;br /&gt;
realistic last step use &amp;lt;strong&amp;gt;one&amp;lt;/strong&amp;gt; of these commands to load&lt;br /&gt;
the full results corresponding to what you have been working with.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
### for CIN subtype:&lt;br /&gt;
load(&amp;amp;#39;/home/projects/22126_NGS/exercises/transcriptomics/03_coad_cin_ora.Rdata&amp;amp;#39;)&lt;br /&gt;
# loads the &amp;amp;quot;cin_ora&amp;amp;quot; object&lt;br /&gt;
&lt;br /&gt;
### For GS subtype:&lt;br /&gt;
load(&amp;amp;#39;/home/projects/22126_NGS/exercises/transcriptomics/03_coad_gs_ora.Rdata&amp;amp;#39;)&lt;br /&gt;
# loads the gs_ora object&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;The following code &amp;lt;em&amp;gt;example&amp;lt;/em&amp;gt; extract the ORA analysis of&lt;br /&gt;
either DGU and DGE and sorts it so the most significant gene-sets are at&lt;br /&gt;
the top.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
### DGE:&lt;br /&gt;
dge_ora_sorted &amp;amp;lt;- gi_paired_ora[&lt;br /&gt;
    sort.list(gi_paired_ora$pval_deseq),                 # sort part&lt;br /&gt;
    c(&amp;amp;#39;pathway&amp;amp;#39;,&amp;amp;#39;pval_deseq&amp;amp;#39;,&amp;amp;#39;enrichment_score_deseq&amp;amp;#39;)   # select part&lt;br /&gt;
]&lt;br /&gt;
&lt;br /&gt;
### DGU ORA:&lt;br /&gt;
dgu_ora_sorted &amp;amp;lt;- gi_paired_ora[&lt;br /&gt;
    sort.list(gi_paired_ora$pval_dexseq),                # sort part&lt;br /&gt;
    c(&amp;amp;#39;pathway&amp;amp;#39;,&amp;amp;#39;pval_dexseq&amp;amp;#39;,&amp;amp;#39;enrichment_score_dexseq&amp;amp;#39;) # select part&lt;br /&gt;
]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: Look at the 10-15 most significant gene&lt;br /&gt;
sets from both analyses. What are the similarities and differences?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-9-visual-inspection-of-ora-result&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 9: Visual inspection of ORA result&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: Based on your insights from step 8 use the &#039;plot_ora()&#039; functionality to test if these are just examples or generalize to all the significant results. An example: If I from the 10-15 top gene-sets saw that only DGU had gene-sets covering “telomer” function I would use the &#039;plot_ora()&#039; function to test this.&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: Try to make a hypothesis as to why this/these molecular functions might be important for cancer.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-10-critical-self-evaluation&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 10: Critical self evaluation&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;Question&amp;lt;/strong&amp;gt;: Take a moment to think about what potential problems there could be with this assignment. Are there any obvious things we have not taken into consideration?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;step-11-repport-result&amp;quot; class=&amp;quot;section level2&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Step 11: Report result&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Go to the blackboard and report one or more of the following:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;A keyword that showed a similar enrichment pattern in DGU and DGE&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;A keyword that showed preferential regulation through DGU or DGE&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;bonus-assignment&amp;quot; class=&amp;quot;section level1&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;h1&amp;gt;Bonus Assignment&amp;lt;/h1&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Use &#039;pairedGSEA&#039; to analyze the other COAD cancer subtype (the one you did not analyze). Are the gene-sets similar or different between the subtypes and analysis types?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_part_2&amp;diff=382</id>
		<title>SNP calling exercise part 2</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_part_2&amp;diff=382"/>
		<updated>2026-01-07T10:59:25Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Filtering&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We have seen that the VCF contains some low-quality or unreliable variant calls. Before downstream analyses, we generally want to &amp;lt;b&amp;gt;remove poor-quality sites&amp;lt;/b&amp;gt; or annotate them so they can be excluded later. In this exercise we explore how to apply &amp;lt;b&amp;gt;hard filters&amp;lt;/b&amp;gt; and how to remove variants in regions of poor mappability.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please use the VCF file generated in Part 1.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Hard Filtering&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Soft filtering approaches (e.g. VQSR) attempt to statistically learn which variants are “true.” However, these approaches require large cohorts or population-level resources, which may not exist for many organisms or under-sampled populations. For this reason, we often fall back on &amp;lt;b&amp;gt;hard filtering&amp;lt;/b&amp;gt;, i.e. applying fixed cutoffs.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Hard filtering is simple but may introduce bias if the filter correlates with variant type (e.g. heterozygous sites often have lower depth). Filters should be chosen thoughtfully.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use the following genomic mask file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/databases/databases/GRCh38/mask99.bed.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This file is in the &amp;lt;b&amp;gt;BED interval format&amp;lt;/b&amp;gt;, which stores genomic regions as:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chromosome   start(0-based)   end(1-based)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;0-based&amp;lt;/b&amp;gt;: first base has coordinate 0&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;1-based&amp;lt;/b&amp;gt;: first base has coordinate 1&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This mask contains genomic regions to &amp;lt;b&amp;gt;exclude&amp;lt;/b&amp;gt; (often low-quality or repetitive regions). Because most genotypers do not recognize duplicated regions, combining hard filtering with mappability filters is best practice.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;A typical hard-filtering command using GATK is:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk VariantFiltration \&lt;br /&gt;
   -V [INPUT VCF] \&lt;br /&gt;
   -O [OUTPUT VCF] \&lt;br /&gt;
   -filter &amp;quot;DP &amp;lt; 10.0&amp;quot;   --filter-name &amp;quot;DP&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;QUAL &amp;lt; 30.0&amp;quot; --filter-name &amp;quot;QUAL30&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;SOR &amp;gt; 3.0&amp;quot;   --filter-name &amp;quot;SOR3&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;FS &amp;gt; 60.0&amp;quot;   --filter-name &amp;quot;FS60&amp;quot; \&lt;br /&gt;
   -filter &amp;quot;MQ &amp;lt; 40.0&amp;quot;   --filter-name &amp;quot;MQ40&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Explanation of filters:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table class=&amp;quot;wikitable&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;Filter&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;Meaning&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;DP &amp;amp;lt; 10&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove sites with &amp;amp;lt;10× coverage&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;QUAL &amp;amp;lt; 30&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove sites where variant quality &amp;amp;lt;30  &lt;br /&gt;
      (variant QUAL ≠ genotype quality GQ — explanation:  &lt;br /&gt;
      [https://gatk.broadinstitute.org/hc/en-us/articles/360035531392 Variant QUAL vs GQ])&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;SOR &amp;amp;gt; 3.0&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove sites with strong strand bias  &lt;br /&gt;
      ([https://gatk.broadinstitute.org/hc/en-us/articles/360036361772 StrandOddsRatio])&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;FS &amp;amp;gt; 60&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove variants failing Fisher Strand bias test  &lt;br /&gt;
      ([https://gatk.broadinstitute.org/hc/en-us/articles/360036361992 FisherStrand])&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;&amp;lt;code&amp;gt;MQ &amp;amp;lt; 40&amp;lt;/code&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;Remove sites where reads have low mapping quality&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; No filter is perfect — you should progressively add filters, evaluate their impact, and ensure that you do not introduce unwanted biases.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q1&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;How many sites were filtered out?  &lt;br /&gt;
Sites that pass all filters have &amp;lt;code&amp;gt;PASS&amp;lt;/code&amp;gt; in the 7th column. Use &amp;lt;code&amp;gt;grep&amp;lt;/code&amp;gt; to count PASS vs non-PASS entries.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q2&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;The 7th column contains the name(s) of the filters that failed.  &lt;br /&gt;
Using &amp;lt;code&amp;gt;cut&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;sort&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;uniq -c&amp;lt;/code&amp;gt;, determine which filter removed the most sites.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Filtering by Mappability&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we remove variants that fall inside &amp;lt;b&amp;gt;low-mappability regions&amp;lt;/b&amp;gt;, because reads cannot be uniquely mapped there and false positives are common.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use &amp;lt;b&amp;gt;bedtools intersect&amp;lt;/b&amp;gt; to retain only variants located in high-mappability intervals (≥99% unique mappability):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bedtools intersect -header \&lt;br /&gt;
   -a [INPUT VCF] \&lt;br /&gt;
   -b /home/databases/databases/GRCh38/filter99.bed.gz \&lt;br /&gt;
 | /home/ctools/htslib-1.20/bgzip -c &amp;gt; [OUTPUT VCF]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Name your output:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NA24694_hf_map99.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The &amp;quot;99&amp;quot; refers to the proportion of synthetic reads that map uniquely at that position.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q3&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;How many variants remain after removing low-mappability regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Annotation of Variants&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we examine the &amp;lt;b&amp;gt;genomic context&amp;lt;/b&amp;gt; of variants: intronic, exonic, intergenic, UTR, etc. We use &amp;lt;b&amp;gt;snpEff&amp;lt;/b&amp;gt; for variant annotation.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
java -jar /home/ctools/snpEff/snpEff.jar eff \&lt;br /&gt;
   -dataDir /home/databases/databases/snpEff/ \&lt;br /&gt;
   -htmlStats [OUTPUT HTML] \&lt;br /&gt;
   GRCh38.99 \&lt;br /&gt;
   [INPUT VCF] \&lt;br /&gt;
 | /home/ctools/htslib-1.20/bgzip -c &amp;gt; [OUTPUT VCF]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-dataDir&amp;lt;/code&amp;gt;: location of snpEff databases&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;GRCh38.99&amp;lt;/code&amp;gt;: genome version — must match the reference genome you used earlier&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run &amp;lt;code&amp;gt;snpEff&amp;lt;/code&amp;gt; on your hard-filtered VCF (before mappability filtering).&lt;br /&gt;
This produces:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HTML report: &amp;lt;code&amp;gt;NA24694_hf.html&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Annotated VCF: &amp;lt;code&amp;gt;NA24694_hf_ann.vcf.gz&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing the snpEff HTML report:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the HTML file directly from the&lt;br /&gt;
left-hand file panel.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML file to&lt;br /&gt;
your local computer and open it in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/NA24694_hf.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q4&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;Which genomic region category contains the most variants (exon, intron, upstream, downstream, UTR, etc.)?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Q5&amp;lt;/h4&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;How many variants are predicted to cause a &amp;lt;b&amp;gt;codon change&amp;lt;/b&amp;gt;?  &lt;br /&gt;
See explanations at: [https://en.wikipedia.org/wiki/Point_mutation Point mutation]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please find answers here:  &lt;br /&gt;
&amp;lt;a href=&amp;quot;SNP_calling_exercise_part_2_answers&amp;quot;&amp;gt;SNP_calling_exercise_part_2_answers&amp;lt;/a&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations — you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;i&amp;gt;Note:&amp;lt;/i&amp;gt; When piping &amp;lt;code&amp;gt;bcftools view&amp;lt;/code&amp;gt; into other tools, consider specifying the output type using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
-O {b|u|z|v}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This avoids unnecessary compression/decompression and speeds up workflows.&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=381</id>
		<title>Exercise and answers</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=381"/>
		<updated>2026-01-07T10:17:33Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt; &amp;lt;b&amp;gt;You will get notified something is missing, just accept&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
eval &amp;quot;$(/home/ctools/miniconda3/bin/conda shell.bash hook)&amp;quot;&lt;br /&gt;
conda activate &amp;quot;$HOME/envs/tadbit_course&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
# also a log folder for the scripts&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
# Filtered fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the template with your favorite editor, paste the following into the file, and save it.&lt;br /&gt;
For example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE;&lt;br /&gt;
cd ${data_dir};&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We can make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5–10 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A prepared script is also available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ~/3D_GENOMICS_COURSE/SCRIPTS;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch .;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While genome indexing runs, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the template and create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/01_fastp.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into the SBATCH script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
fastp \&lt;br /&gt;
    # Read raw fastq from course folders&lt;br /&gt;
    -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
    # Store the clean fastq version in your folder&lt;br /&gt;
    -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
    -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
    -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
    --detect_adapter_for_pe \&lt;br /&gt;
    # Trim first 5 bases (often lower quality)&lt;br /&gt;
    --trim_front1 5 \&lt;br /&gt;
    # Threads&lt;br /&gt;
    -w 10 \&lt;br /&gt;
    # Minimal read length (remove reads shorter than this after trimming)&lt;br /&gt;
    -l 30 \&lt;br /&gt;
    -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the HTML report to your local computer and open it in a browser:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
USER=&amp;quot;juanrod&amp;quot;&lt;br /&gt;
scp ${USER}@pupil1.healthtech.dtu.dk:/home/people/${USER}/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into your mapping script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for mapping&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;  # Double digestion (relevant for Arima/Phase Genomics)&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1;&lt;br /&gt;
&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --tmpdb ${TMPDIR} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
# &amp;gt;&amp;gt;&amp;gt; Just change the script to take that as a parameter.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; We are not using iterative mapping. Fragment-based mapping is the default in TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Fragment size histogram&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HiC sequencing quality and digestion/ligation deconvolution&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
ref=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# Keep only canonical chromosomes and compress map files after parsing&lt;br /&gt;
tadbit parse \&lt;br /&gt;
       --workdir ${wd} \&lt;br /&gt;
       --genome ${ref} \&lt;br /&gt;
       --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
       --compress_input;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~35 min to complete with 10 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Run filtering:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --tmpdb ${TMPDIR}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Change to workdir&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
# Summarize the run&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# First time we define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Choice of normalization (raw, ICE, Vanilla, decay)&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit normalize -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       --tmpdb ${TMPDIR} \&lt;br /&gt;
       --cpus 6 \&lt;br /&gt;
       --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
       --normalization ${norm} \&lt;br /&gt;
       --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
       --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~2 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⚠️ Run another version with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt; to compare later.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each job is assigned a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;. This helps retrieve results from specific runs (especially when testing parameters).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want, you can take a quick look at the different normalization strategies and extract your own conclusions:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Variables used for binning&lt;br /&gt;
&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
res=&amp;quot;100000&amp;quot;;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit bin \&lt;br /&gt;
       -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       -c ${chrom} \&lt;br /&gt;
       --plot \&lt;br /&gt;
       --norm &amp;quot;norm&amp;quot; \&lt;br /&gt;
       --format &amp;quot;png&amp;quot; \&lt;br /&gt;
       --cpus 6;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=380</id>
		<title>Exercise and answers</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=380"/>
		<updated>2026-01-07T10:17:00Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later &amp;lt;b&amp;gt;You will get notified something is missing, just accept&amp;lt;/b&amp;gt;&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
eval &amp;quot;$(/home/ctools/miniconda3/bin/conda shell.bash hook)&amp;quot;&lt;br /&gt;
conda activate &amp;quot;$HOME/envs/tadbit_course&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
# also a log folder for the scripts&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
# Filtered fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the template with your favorite editor, paste the following into the file, and save it.&lt;br /&gt;
For example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE;&lt;br /&gt;
cd ${data_dir};&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We can make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5–10 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A prepared script is also available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ~/3D_GENOMICS_COURSE/SCRIPTS;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch .;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While genome indexing runs, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the template and create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/01_fastp.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into the SBATCH script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
fastp \&lt;br /&gt;
    # Read raw fastq from course folders&lt;br /&gt;
    -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
    # Store the clean fastq version in your folder&lt;br /&gt;
    -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
    -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
    -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
    --detect_adapter_for_pe \&lt;br /&gt;
    # Trim first 5 bases (often lower quality)&lt;br /&gt;
    --trim_front1 5 \&lt;br /&gt;
    # Threads&lt;br /&gt;
    -w 10 \&lt;br /&gt;
    # Minimal read length (remove reads shorter than this after trimming)&lt;br /&gt;
    -l 30 \&lt;br /&gt;
    -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the HTML report to your local computer and open it in a browser:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
USER=&amp;quot;juanrod&amp;quot;&lt;br /&gt;
scp ${USER}@pupil1.healthtech.dtu.dk:/home/people/${USER}/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into your mapping script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for mapping&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;  # Double digestion (relevant for Arima/Phase Genomics)&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1;&lt;br /&gt;
&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --tmpdb ${TMPDIR} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
# &amp;gt;&amp;gt;&amp;gt; Just change the script to take that as a parameter.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; We are not using iterative mapping. Fragment-based mapping is the default in TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Fragment size histogram&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HiC sequencing quality and digestion/ligation deconvolution&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
ref=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# Keep only canonical chromosomes and compress map files after parsing&lt;br /&gt;
tadbit parse \&lt;br /&gt;
       --workdir ${wd} \&lt;br /&gt;
       --genome ${ref} \&lt;br /&gt;
       --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
       --compress_input;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~35 min to complete with 10 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Run filtering:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --tmpdb ${TMPDIR}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Change to workdir&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
# Summarize the run&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# First time we define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Choice of normalization (raw, ICE, Vanilla, decay)&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit normalize -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       --tmpdb ${TMPDIR} \&lt;br /&gt;
       --cpus 6 \&lt;br /&gt;
       --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
       --normalization ${norm} \&lt;br /&gt;
       --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
       --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~2 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⚠️ Run another version with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt; to compare later.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each job is assigned a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;. This helps retrieve results from specific runs (especially when testing parameters).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want, you can take a quick look at the different normalization strategies and extract your own conclusions:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Variables used for binning&lt;br /&gt;
&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
res=&amp;quot;100000&amp;quot;;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit bin \&lt;br /&gt;
       -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       -c ${chrom} \&lt;br /&gt;
       --plot \&lt;br /&gt;
       --norm &amp;quot;norm&amp;quot; \&lt;br /&gt;
       --format &amp;quot;png&amp;quot; \&lt;br /&gt;
       --cpus 6;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=379</id>
		<title>Exercise and answers</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Exercise_and_answers&amp;diff=379"/>
		<updated>2026-01-07T10:12:57Z</updated>

		<summary type="html">&lt;p&gt;Mick: Created page with &amp;quot;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;  &amp;lt;p&amp;gt; In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017): from FASTQ files to contact matrix and beyond. &amp;lt;/p&amp;gt;  &amp;lt;p&amp;gt; &amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt; Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt; 9 January 2026, DTU &amp;lt;/p&amp;gt;  &amp;lt;hr&amp;gt;  &amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;  &amp;lt;ol&amp;gt;   &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;   &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;   &amp;lt;li&amp;gt;Use TADbit to:     &amp;lt;ol&amp;gt;...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
conda activate /home/people/${USER}/envs/tadbit_course&lt;br /&gt;
# $USER is your user; it&#039;s an environment variable so no need to change it.&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
# also a log folder for the scripts&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
# Filtered fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the template with your favorite editor, paste the following into the file, and save it.&lt;br /&gt;
For example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE;&lt;br /&gt;
cd ${data_dir};&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We can make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5–10 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A prepared script is also available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ~/3D_GENOMICS_COURSE/SCRIPTS;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch .;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While genome indexing runs, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the template and create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/01_fastp.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into the SBATCH script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
fastp \&lt;br /&gt;
    # Read raw fastq from course folders&lt;br /&gt;
    -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
    # Store the clean fastq version in your folder&lt;br /&gt;
    -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
    -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
    -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
    --detect_adapter_for_pe \&lt;br /&gt;
    # Trim first 5 bases (often lower quality)&lt;br /&gt;
    --trim_front1 5 \&lt;br /&gt;
    # Threads&lt;br /&gt;
    -w 10 \&lt;br /&gt;
    # Minimal read length (remove reads shorter than this after trimming)&lt;br /&gt;
    -l 30 \&lt;br /&gt;
    -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the HTML report to your local computer and open it in a browser:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
USER=&amp;quot;juanrod&amp;quot;&lt;br /&gt;
scp ${USER}@pupil1.healthtech.dtu.dk:/home/people/${USER}/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into your mapping script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for mapping&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;  # Double digestion (relevant for Arima/Phase Genomics)&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1;&lt;br /&gt;
&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --tmpdb ${TMPDIR} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
# &amp;gt;&amp;gt;&amp;gt; Just change the script to take that as a parameter.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; We are not using iterative mapping. Fragment-based mapping is the default in TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Fragment size histogram&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HiC sequencing quality and digestion/ligation deconvolution&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
ref=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# Keep only canonical chromosomes and compress map files after parsing&lt;br /&gt;
tadbit parse \&lt;br /&gt;
       --workdir ${wd} \&lt;br /&gt;
       --genome ${ref} \&lt;br /&gt;
       --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
       --compress_input;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~35 min to complete with 10 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Run filtering:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --tmpdb ${TMPDIR}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Change to workdir&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
# Summarize the run&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# First time we define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Choice of normalization (raw, ICE, Vanilla, decay)&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit normalize -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       --tmpdb ${TMPDIR} \&lt;br /&gt;
       --cpus 6 \&lt;br /&gt;
       --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
       --normalization ${norm} \&lt;br /&gt;
       --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
       --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~2 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⚠️ Run another version with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt; to compare later.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each job is assigned a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;. This helps retrieve results from specific runs (especially when testing parameters).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want, you can take a quick look at the different normalization strategies and extract your own conclusions:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Variables used for binning&lt;br /&gt;
&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
res=&amp;quot;100000&amp;quot;;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit bin \&lt;br /&gt;
       -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       -c ${chrom} \&lt;br /&gt;
       --plot \&lt;br /&gt;
       --norm &amp;quot;norm&amp;quot; \&lt;br /&gt;
       --format &amp;quot;png&amp;quot; \&lt;br /&gt;
       --cpus 6;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_part_1&amp;diff=378</id>
		<title>SNP calling exercise part 1</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_part_1&amp;diff=378"/>
		<updated>2026-01-07T10:00:14Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise you will perform basic variant calling and start exploring VCF files. You will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run a germline variant caller on whole-genome sequencing data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Get acquainted with VCF and gVCF formats&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Count and subset variants using command-line tools&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Compare “known” vs “novel” variants&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;variant_call&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Enter the &amp;lt;code&amp;gt;variant_call&amp;lt;/code&amp;gt; directory&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Genotyping&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will genotype chromosome 20 from a BAM file that has been pre-processed (sorted, duplicate-marked, etc.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The sample is a [https://en.wikipedia.org/wiki/Han_Chinese Han Chinese] male, sequenced to approximately 24.6x coverage.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/snp_calling/NA24694.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The BAM file is already indexed.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use &amp;lt;b&amp;gt;GATK HaplotypeCaller&amp;lt;/b&amp;gt; to generate a gVCF file. A typical command looks like this:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk --java-options &amp;quot;-Xmx10g&amp;quot; HaplotypeCaller \&lt;br /&gt;
    -R /home/databases/references/human/GRCh38_full_analysis_set_plus_decoy_hla.fa \&lt;br /&gt;
    -I [INPUT_BAM] \&lt;br /&gt;
    -L chr20 \&lt;br /&gt;
    -O [OUTPUT_GVCF] \&lt;br /&gt;
    --dbsnp /home/databases/databases/GRCh38/Homo_sapiens_assembly38.dbsnp138.vcf.gz \&lt;br /&gt;
    -ERC GVCF&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Explanation of the key options:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-R&amp;lt;/code&amp;gt; – reference genome (GRCh38)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-I&amp;lt;/code&amp;gt; – input BAM file (here: &amp;lt;code&amp;gt;NA24694.bam&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-L chr20&amp;lt;/code&amp;gt; – restrict calling to chromosome 20&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;--dbsnp&amp;lt;/code&amp;gt; – annotate with known variants from dbSNP&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-ERC GVCF&amp;lt;/code&amp;gt; – emit a gVCF (includes both variant and non-variant blocks)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Suggested output name:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NA24694.gvcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This command may take a while to complete. If you are short on time, you can use the precomputed file instead:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/snp_calling/NA24694.gvcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Take a quick look at the gVCF:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat NA24694.gvcf.gz | less -S&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Notes:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Lines starting with &amp;lt;code&amp;gt;#&amp;lt;/code&amp;gt; form the header.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Data lines have at least 10 columns. The first five are:&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;CHROM – chromosome name&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;POS – genomic coordinate&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;ID – variant identifier (e.g. dbSNP ID, or &amp;lt;code&amp;gt;.&amp;lt;/code&amp;gt; if unknown)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;REF – reference allele&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;ALT – alternate allele(s)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;In gVCFs, you will often see &amp;lt;code&amp;gt;&amp;amp;lt;NON_REF&amp;amp;gt;&amp;lt;/code&amp;gt; as the ALT allele for invariant blocks.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Indexing the gVCF&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Before using the gVCF as input for other tools, index it with &amp;lt;b&amp;gt;tabix&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix -f -p vcf [INPUT_GVCF]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This creates an index file with extension &amp;lt;code&amp;gt;.tbi&amp;lt;/code&amp;gt;, allowing fast random access by position.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Genotyping the gVCF (producing a standard VCF)&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we convert the gVCF into a standard VCF with genotypes only at variant sites using &amp;lt;b&amp;gt;GATK GenotypeGVCFs&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk GenotypeGVCFs \&lt;br /&gt;
    -R /home/databases/references/human/GRCh38_full_analysis_set_plus_decoy_hla.fa \&lt;br /&gt;
    -V [INPUT_GVCF] \&lt;br /&gt;
    -O [OUTPUT_VCF] \&lt;br /&gt;
    -L chr20 \&lt;br /&gt;
    --dbsnp /home/databases/databases/GRCh38/Homo_sapiens_assembly38.dbsnp138.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Suggested output name:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NA24694.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This step is usually faster than HaplotypeCaller.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the VCF with tabix:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix -f -p vcf NA24694.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;As with BAM indices, the VCF index allows fast region-based queries, but here using tabix rather than samtools.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Getting Acquainted with VCF Files&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; Using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools stats [INPUT_VCF]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Find the line that starts with:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SN    0    number of SNPs&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;How many SNPs are present in your VCF?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can query specific regions of the VCF using tabix:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix [INPUT_VCF] [CHROM]:[START]-[END]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;For a single coordinate:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix [INPUT_VCF] [CHROM]:[POS]-[POS]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2.&amp;lt;/b&amp;gt; Using tabix and &amp;lt;code&amp;gt;wc -l&amp;lt;/code&amp;gt;, how many total variants are present in the 1 Mb region:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:32000000-33000000&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;(Remember that tabix only returns data lines, so you can safely count lines with &amp;lt;code&amp;gt;wc -l&amp;lt;/code&amp;gt;.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3.&amp;lt;/b&amp;gt; &amp;lt;code&amp;gt;bcftools&amp;lt;/code&amp;gt; can subset and filter VCF files.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Type:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bcftools-1.23/bcftools view&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;and look at the help text. Using &amp;lt;code&amp;gt;bcftools view&amp;lt;/code&amp;gt;, determine how many &amp;lt;b&amp;gt;SNPs&amp;lt;/b&amp;gt; (excluding indels and multi-allelic variants) are present in the &amp;lt;b&amp;gt;same region&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:32000000-33000000&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Hints:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Filter for variant type (SNPs only).&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use &amp;lt;code&amp;gt;-H&amp;lt;/code&amp;gt; to avoid counting header lines.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Pipe the result to &amp;lt;code&amp;gt;wc -l&amp;lt;/code&amp;gt; to count variants.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4.&amp;lt;/b&amp;gt; Retrieve the variants at:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:32011209&lt;br /&gt;
chr20:32044279&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can use either tabix or bcftools, for example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix NA24694.vcf.gz chr20:32011209-32011209&lt;br /&gt;
/home/ctools/htslib-1.20/tabix NA24694.vcf.gz chr20:32044279-32044279&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;For each site, answer:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What is the genotype (e.g. 0/0, 0/1, 1/1)?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What is the allele depth (AD) – how many reads support each allele?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What is the total depth of coverage (DP) at this site?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What is the genotype quality (GQ)?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What are the genotype likelihoods (PL)?&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the VCF specification (&amp;lt;a href=&amp;quot;https://samtools.github.io/hts-specs/VCFv4.2.pdf&amp;quot;&amp;gt;VCFv4.2&amp;lt;/a&amp;gt;, especially section 1.4 “Data lines”) and GATK’s VCF documentation (&amp;lt;a href=&amp;quot;https://gatk.broadinstitute.org/hc/en-us/articles/360035531692-VCF-Variant-Call-Format&amp;quot;&amp;gt;GATK VCF Format&amp;lt;/a&amp;gt;) to interpret the FORMAT fields.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5.&amp;lt;/b&amp;gt; Inspect the SNPs at positions:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20    32974911&lt;br /&gt;
chr20    64291638&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;One of these SNPs has poor quality, the other has good quality.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Which is which?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Why do you think this is the case? (Hint: think about depth, allele balance, and overall evidence.)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6.&amp;lt;/b&amp;gt; Using the same region as in Q2/Q3:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:32000000-33000000&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;How many SNPs in this region are &amp;lt;b&amp;gt;novel&amp;lt;/b&amp;gt;, i.e. do not have an ID in dbSNP?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Hints:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;The 3rd column (ID) contains dbSNP IDs (typically starting with &amp;lt;code&amp;gt;rs&amp;lt;/code&amp;gt;) or &amp;lt;code&amp;gt;.&amp;lt;/code&amp;gt; for novel variants.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;You can use &amp;lt;code&amp;gt;cut&amp;lt;/code&amp;gt; to extract the ID column.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;grep&amp;lt;/code&amp;gt; with &amp;lt;code&amp;gt;-v&amp;lt;/code&amp;gt; can be used to exclude lines containing &amp;lt;code&amp;gt;rs&amp;lt;/code&amp;gt;, or to include only those lines.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7.&amp;lt;/b&amp;gt; Compare your result from Q6 (number of novel SNPs) to the number of SNPs you found in Q3 (total SNPs in the region).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What fraction of SNPs in this region are novel?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Does this fraction seem reasonable, given that human variation databases are large but still incomplete?&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=377</id>
		<title>Alignment exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=377"/>
		<updated>2026-01-07T09:47:53Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise you will practice aligning NGS data and working with alignment files.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;align&amp;lt;/code&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to the &amp;lt;code&amp;gt;align&amp;lt;/code&amp;gt; directory.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will align two types of NGS data:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;i&amp;gt;Pseudomonas&amp;lt;/i&amp;gt; single-end Illumina reads&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Human paired-end Illumina reads&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;&amp;lt;i&amp;gt;P. aeruginosa&amp;lt;/i&amp;gt; single-end Illumina reads&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Alignment using bwa mem&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will align single-end reads that have been trimmed from &amp;lt;i&amp;gt;P. aeruginosa&amp;lt;/i&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Raw data:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;/home/projects/22126_NGS/exercises/alignment/SRR8002634_1.fastq.gz&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Trimmed data:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;/home/projects/22126_NGS/exercises/alignment/SRR8002634_1_trimmed.fq.gz&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Reference genome:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;/home/databases/references/P_aeruginosa/GCF_000006765.1_ASM676v1_genomic.fasta&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The basic &amp;lt;code&amp;gt;bwa mem&amp;lt;/code&amp;gt; command to align single-end reads is:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;bwa mem [reference.fasta] [reads.fastq.gz] &amp;amp;gt; [output.sam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Remember: the &amp;lt;code&amp;gt;&amp;amp;gt;&amp;lt;/code&amp;gt; operator redirects standard output (STDOUT) to a file.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We have discussed multiplexing and read groups. It is good practice to add a read group ID and sample name during alignment. For example, if the read group is &amp;lt;code&amp;gt;RG38&amp;lt;/code&amp;gt; and the sample is &amp;lt;code&amp;gt;SMPL96&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;bwa mem -R &amp;quot;@RG\tID:RG38\tSM:SMPL96&amp;quot; [reference.fasta] [reads.fastq.gz] &amp;amp;gt; [output.sam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This information is crucial when you later merge multiple BAM files, so you can trace which reads came from which library or sample.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Task:&amp;lt;/b&amp;gt; Align the &amp;lt;b&amp;gt;trimmed&amp;lt;/b&amp;gt; FASTQ file using the command above.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1:&amp;lt;/b&amp;gt; If you were not told which FASTQ file contains the trimmed reads, how could you determine it from the files themselves? (Hint: think of at least three different ways.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Inspecting the alignment&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Assume you named your output file &amp;lt;code&amp;gt;SRR8002634_1.sam&amp;lt;/code&amp;gt;. You can view it as:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;less -S SRR8002634_1.sam&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The &amp;lt;code&amp;gt;-S&amp;lt;/code&amp;gt; option prevents line wrapping; press &amp;lt;code&amp;gt;q&amp;lt;/code&amp;gt; to quit. Use the slides and the&lt;br /&gt;
[https://samtools.github.io/hts-specs/SAMv1.pdf official SAM specification] to interpret each field.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Answer the following:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2:&amp;lt;/b&amp;gt; How many lines does the header have (lines starting with &amp;lt;code&amp;gt;@&amp;lt;/code&amp;gt;)?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3:&amp;lt;/b&amp;gt; What is the genomic coordinate (reference name and position) of the first read &amp;lt;code&amp;gt;SRR8002634.1&amp;lt;/code&amp;gt;?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4:&amp;lt;/b&amp;gt; What is the mapping quality of the third read &amp;lt;code&amp;gt;SRR8002634.3&amp;lt;/code&amp;gt;? What does that mapping quality tell you about this read?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5:&amp;lt;/b&amp;gt; Using the SAM flag definitions (see&lt;br /&gt;
[https://broadinstitute.github.io/picard/explain-flags.html Picard flag explanation]), determine among the first 8 reads how many map to the &amp;lt;b&amp;gt;forward (+)&amp;lt;/b&amp;gt; strand and how many to the &amp;lt;b&amp;gt;reverse (–)&amp;lt;/b&amp;gt; strand.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6:&amp;lt;/b&amp;gt; Is the 10th read &amp;lt;code&amp;gt;SRR8002634.11&amp;lt;/code&amp;gt; unmapped? (Note: &amp;lt;code&amp;gt;SRR8002634.9&amp;lt;/code&amp;gt; was removed by trimming, so numbering skips.) How did you determine this from the SAM fields?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To get basic alignment statistics, use:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools flagstat [input.sam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Below is a brief explanation of the fields reported by &amp;lt;code&amp;gt;flagstat&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table class=&amp;quot;wikitable&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;th&amp;gt;Category&amp;lt;/th&amp;gt;&lt;br /&gt;
    &amp;lt;th&amp;gt;Meaning&amp;lt;/th&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;mapQ&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Mapping quality&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;QC-passed reads&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Reads not marked as QC-failed; these are typically used for analysis.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;QC-failed reads&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Reads flagged as having problems by the processing pipeline; downstream tools usually ignore them.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;total&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Total number of alignments reported.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;secondary&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Additional alignments for reads that map equally well to multiple locations.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;supplementary&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Alignments for chimeric or split reads where different parts map to different locations.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;duplicates&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Reads marked as duplicates (e.g. PCR duplicates); will be discussed in the next class.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;mapped&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Number of reads with at least one reported alignment (not unmapped).&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;paired in sequencing&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Reads that were sequenced as part of a pair (not single-end).&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;read1&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;First read in the pair (forward).&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;read2&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Second read in the pair (reverse).&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;properly paired&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Pairs that face each other and are within the expected insert size range.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;with itself and mate mapped&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Both the read and its mate are mapped (whether or not properly paired).&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;singletons&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Reads that are mapped but whose mate is unmapped.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;with mate mapped to a different chr&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Reads whose mate is mapped to a different chromosome.&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7:&amp;lt;/b&amp;gt; According to &amp;lt;code&amp;gt;samtools flagstat&amp;lt;/code&amp;gt;, what fraction of reads did &amp;lt;b&amp;gt;not&amp;lt;/b&amp;gt; align to the reference?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Working with alignments&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Format conversion&amp;lt;/h4&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This should be the first and hopefully last time you work directly with SAM for large files.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, check the SAM file size:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;ls -lh SRR8002634_1.sam&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Convert SAM to BAM:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view -bS [input.sam] &amp;amp;gt; [output.bam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Check the BAM file size:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;ls -lh SRR8002634_1.bam&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;code&amp;gt;-l&amp;lt;/code&amp;gt; gives a detailed listing (permissions, size, date). &amp;lt;code&amp;gt;-h&amp;lt;/code&amp;gt; shows file sizes in human-readable form (e.g. 2.4M instead of 2469134 bytes).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The BAM file contains exactly the same alignments as the SAM file, but in binary form. To view it as SAM:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view [input.bam] | less -S&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can filter reads based on SAM flags. For example, to include only unmapped reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view -f 0x4 [input.bam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To exclude unmapped reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view -F 0x4 [input.bam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The flag &amp;lt;code&amp;gt;0x4&amp;lt;/code&amp;gt; corresponds to “read unmapped” (see the&lt;br /&gt;
[https://broadinstitute.github.io/picard/explain-flags.html flag documentation]).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8:&amp;lt;/b&amp;gt; What is the size ratio of SAM to BAM (SAM size divided by BAM size)?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Now convert BAM to CRAM, which compresses further using the reference:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view -C -T [reference.fasta] [input.bam] &amp;amp;gt; [output.cram]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the same reference FASTA you used for mapping. Check the CRAM file size with &amp;lt;code&amp;gt;ls -lh&amp;lt;/code&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To view CRAM as SAM:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view -T [reference.fasta] [input.cram] | less -S&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9:&amp;lt;/b&amp;gt; What is the size ratio of BAM to CRAM?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To save space, please remove the SAM and CRAM files (we will work with BAM only):&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;rm [file]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Sorting&amp;lt;/h4&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Sort the BAM file by genomic coordinate:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools sort [input.bam] &amp;amp;gt; [output.sorted.bam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Be careful not to overwrite the original BAM file; for example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;input.bam&amp;lt;/code&amp;gt; = &amp;lt;code&amp;gt;SRR8002634_1.bam&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;output.sorted.bam&amp;lt;/code&amp;gt; = &amp;lt;code&amp;gt;SRR8002634_1.sorted.bam&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use &amp;lt;code&amp;gt;samtools view&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;less -S&amp;lt;/code&amp;gt; to confirm that reads are ordered by reference and coordinate.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the sorted BAM file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools index [input.sorted.bam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Note: you &amp;lt;b&amp;gt;cannot&amp;lt;/b&amp;gt; index an unsorted BAM file.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Retrieving a particular region&amp;lt;/h4&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Once sorted and indexed, you can retrieve reads from a specific region:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view [input.sorted.bam] [regionID]:[start]-[end]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;For example, to get reads overlapping positions 1,000,000–1,000,100 on chromosome &amp;lt;code&amp;gt;NC_002516.2&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view SRR8002634_1.sorted.bam NC_002516.2:1000000-1000100&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10:&amp;lt;/b&amp;gt; How many reads are aligned between positions 2,000,000 and 3,000,000 on the reference &amp;lt;code&amp;gt;NC_002516.2&amp;lt;/code&amp;gt;?&amp;lt;br&amp;gt;&lt;br /&gt;
Hint: do not save to a file; instead use:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view [options] | wc -l&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11:&amp;lt;/b&amp;gt; How many reads with mapping quality &amp;lt;b&amp;gt;&amp;amp;ge; 30&amp;lt;/b&amp;gt; are aligned between positions 2,000,000 and 3,000,000 on &amp;lt;code&amp;gt;NC_002516.2&amp;lt;/code&amp;gt;?&amp;lt;br&amp;gt;&lt;br /&gt;
Hint: run &amp;lt;code&amp;gt;samtools view&amp;lt;/code&amp;gt; without arguments to see its options.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;Average coverage&amp;lt;/h4&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use &amp;lt;code&amp;gt;mosdepth&amp;lt;/code&amp;gt; to measure the average coverage (mean number of reads covering each base in the genome):&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;/home/ctools/mosdepth/mosdepth [output_prefix] [input.sorted.bam]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use any prefix you like (e.g. &amp;lt;code&amp;gt;SRR8002634_1&amp;lt;/code&amp;gt;). &amp;lt;code&amp;gt;mosdepth&amp;lt;/code&amp;gt; will write a summary file named &amp;lt;code&amp;gt;[output_prefix].mosdepth.summary.txt&amp;lt;/code&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Check the summary and see if the reported coverage makes sense given the data.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12:&amp;lt;/b&amp;gt; On average, how many reads cover a base in the genome? What is the maximum coverage (maximum number of reads covering a single position)?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can also inspect per-position coverage using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools mpileup [input.sorted.bam] | less -S&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;The wrong reference genome?&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q13:&amp;lt;/b&amp;gt; Suppose you accidentally aligned the reads to a different bacterial reference genome, e.g. &amp;lt;i&amp;gt;Yersinia pestis&amp;lt;/i&amp;gt; (the plague bacterium), a distant relative of &amp;lt;i&amp;gt;Pseudomonas alcaligenes&amp;lt;/i&amp;gt;. Would the number of aligned reads go up or down compared to the correct reference? Why? What if the other species was very closely related — would you expect more or fewer reads to align?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Optional bonus:&amp;lt;/b&amp;gt; Try it.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;&amp;lt;i&amp;gt;Yersinia pestis&amp;lt;/i&amp;gt; reference:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;/home/databases/references/Y_pestis/GCF_000222975.1_ASM22297v1_genomic.fasta&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;&amp;lt;i&amp;gt;Pseudomonas alcaligenes&amp;lt;/i&amp;gt; reference:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;/home/databases/references/P_alcaligenes/GCF_001597285.1_ASM159728v1_genomic.fasta&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Human paired-end Illumina reads&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Aligning&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will align exome-seq reads from a [https://en.wikipedia.org/wiki/Yoruba_people Yoruba] female.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Raw data:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;/home/projects/22126_NGS/exercises/alignment/NA19201_1.fastq.gz&lt;br /&gt;
/home/projects/22126_NGS/exercises/alignment/NA19201_2.fastq.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;code&amp;gt;NA19201_1.fastq.gz&amp;lt;/code&amp;gt; contains the forward reads; &amp;lt;code&amp;gt;NA19201_2.fastq.gz&amp;lt;/code&amp;gt; contains the reverse reads. These reads are already trimmed.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Your goal is to write a &amp;lt;b&amp;gt;single command line&amp;lt;/b&amp;gt; that:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Uses &amp;lt;code&amp;gt;bwa mem&amp;lt;/code&amp;gt; to align the paired-end reads and produce SAM output.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Converts SAM to BAM.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Sorts the BAM file.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;&amp;lt;code&amp;gt;bwa mem&amp;lt;/code&amp;gt; syntax for paired-end reads:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;bwa mem [reference.fasta] [forward.fastq.gz] [reverse.fastq.gz]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Human reference (GRCh38):&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;/home/databases/references/human/GRCh38_full_analysis_set_plus_decoy_hla.fa&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; There are multiple versions of the human reference genome (e.g. hg18, hg19, hg38). Coordinates and even sequences can differ between versions. Always make sure to use the &amp;lt;b&amp;gt;same reference version&amp;lt;/b&amp;gt; consistently in all steps of your analysis.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If possible, add a read group and sample name. For example, if read group is &amp;lt;code&amp;gt;RG26&amp;lt;/code&amp;gt; and sample is &amp;lt;code&amp;gt;YRB42&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;-R &amp;quot;@RG\tID:RG26\tSM:YRB42&amp;quot;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Converting and sorting:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;samtools view -bS [input.sam]&amp;lt;/code&amp;gt; converts SAM to BAM.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;When reading from STDIN, use &amp;lt;code&amp;gt;/dev/stdin&amp;lt;/code&amp;gt; as the input.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;samtools sort [input.bam]&amp;lt;/code&amp;gt; sorts the BAM file.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Your combined command should:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run &amp;lt;code&amp;gt;bwa mem&amp;lt;/code&amp;gt;,&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Pipe SAM output to &amp;lt;code&amp;gt;samtools view&amp;lt;/code&amp;gt;,&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Pipe BAM output to &amp;lt;code&amp;gt;samtools sort&amp;lt;/code&amp;gt;,&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Redirect the final sorted BAM to &amp;lt;code&amp;gt;NA19201.bam&amp;lt;/code&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The alignment may take around 10 minutes.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14:&amp;lt;/b&amp;gt; Write the full one-line command that performs alignment, SAM-&amp;amp;gt;BAM conversion, and sorting using pipes, and saves output as &amp;lt;code&amp;gt;NA19201.bam&amp;lt;/code&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q15:&amp;lt;/b&amp;gt; What are two major advantages of using UNIX pipes instead of running each command separately and writing intermediate files?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; For speed, the provided reads only contain sequences mapping to &amp;lt;code&amp;gt;chr20&amp;lt;/code&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Alignment statistics&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;flagstat&amp;lt;/h4&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q16:&amp;lt;/b&amp;gt; Using &amp;lt;code&amp;gt;samtools flagstat&amp;lt;/code&amp;gt;, what proportion of reads aligned to the reference?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q17:&amp;lt;/b&amp;gt; Using the same output, how many read pairs are marked as &amp;lt;b&amp;gt;properly paired&amp;lt;/b&amp;gt;?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q18:&amp;lt;/b&amp;gt; Index the BAM file, then run:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools view [input.bam] [chromosome]&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Count how many reads align to &amp;lt;code&amp;gt;chr20&amp;lt;/code&amp;gt; (hint: pipe to &amp;lt;code&amp;gt;wc -l&amp;lt;/code&amp;gt;). How many total reads are aligned to &amp;lt;code&amp;gt;chr20&amp;lt;/code&amp;gt;?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h4&amp;gt;stat&amp;lt;/h4&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Generate additional alignment statistics using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools stat [input.bam] &amp;gt; NA19201.stat&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Generate plots from the statistics file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
plot-bamstats -p NA19201 NA19201.stat&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing the BAM statistics report:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The command above generates a set of &amp;lt;b&amp;gt;PNG image files&amp;lt;/b&amp;gt; containing&lt;br /&gt;
various BAM statistics (e.g. insert size, base composition, quality by cycle).&lt;br /&gt;
The plots are created in the current directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the PNG files directly from the&lt;br /&gt;
left-hand file panel.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the PNG files to your&lt;br /&gt;
local computer and open them using any image viewer. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/NA19201*.png .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q19:&amp;lt;/b&amp;gt; Look at the &amp;lt;b&amp;gt;insert size distribution&amp;lt;/b&amp;gt; plot. What is the most&lt;br /&gt;
common insert size (approximately)?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Inspecting the alignment with &amp;lt;code&amp;gt;samtools tview&amp;lt;/code&amp;gt;&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use the text-based viewer &amp;lt;code&amp;gt;samtools tview&amp;lt;/code&amp;gt; to inspect the human alignment around a potential variant.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, make sure your BAM file is indexed:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools index NA19201.bam&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then start &amp;lt;code&amp;gt;samtools tview&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools tview NA19201.bam /home/databases/references/human/GRCh38_full_analysis_set_plus_decoy_hla.fa&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This opens the alignment in your terminal.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To jump to the region of interest (&amp;lt;code&amp;gt;chr20:35,581,362&amp;lt;/code&amp;gt;):&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Press &amp;lt;code&amp;gt;g&amp;lt;/code&amp;gt; (for “goto”).&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Type &amp;lt;code&amp;gt;chr20:35581362&amp;lt;/code&amp;gt; and press Enter.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You should now see:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;The reference sequence on the top line.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Aligned reads below. Matching bases are often shown as &amp;lt;code&amp;gt;.&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;,&amp;lt;/code&amp;gt;, while mismatches are shown as the actual base (A/C/G/T).&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Useful keys:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;?&amp;lt;/code&amp;gt; – show help.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Arrow keys – move left/right/up/down.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;q&amp;lt;/code&amp;gt; – quit &amp;lt;code&amp;gt;tview&amp;lt;/code&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use this view to answer the following:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q20:&amp;lt;/b&amp;gt; At position &amp;lt;code&amp;gt;chr20:35,581,362&amp;lt;/code&amp;gt;, what bases are present in the sample reads?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q21:&amp;lt;/b&amp;gt; How many reads support the non-consensus base at this position? (Count the reads showing the alternative base in &amp;lt;code&amp;gt;tview&amp;lt;/code&amp;gt;.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q22:&amp;lt;/b&amp;gt; Based on the fraction of reads supporting the non-reference base, does this variant look more like a heterozygous or a homozygous variant? Explain briefly.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please find the answers [[Alignment_exercise_answers|here]].&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=376</id>
		<title>Alignment exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=376"/>
		<updated>2026-01-07T09:29:03Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
eval &amp;quot;$(/home/ctools/miniconda3/bin/conda shell.bash hook)&amp;quot;&lt;br /&gt;
conda activate &amp;quot;$HOME/envs/tadbit_course&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
# also a log folder for the scripts&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
# Filtered fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the template with your favorite editor, paste the following into the file, and save it.&lt;br /&gt;
For example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE;&lt;br /&gt;
cd ${data_dir};&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We can make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5–10 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A prepared script is also available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ~/3D_GENOMICS_COURSE/SCRIPTS;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch .;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While genome indexing runs, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the template and create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/01_fastp.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into the SBATCH script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
fastp \&lt;br /&gt;
    # Read raw fastq from course folders&lt;br /&gt;
    -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
    # Store the clean fastq version in your folder&lt;br /&gt;
    -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
    -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
    -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
    --detect_adapter_for_pe \&lt;br /&gt;
    # Trim first 5 bases (often lower quality)&lt;br /&gt;
    --trim_front1 5 \&lt;br /&gt;
    # Threads&lt;br /&gt;
    -w 10 \&lt;br /&gt;
    # Minimal read length (remove reads shorter than this after trimming)&lt;br /&gt;
    -l 30 \&lt;br /&gt;
    -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the HTML report to your local computer and open it in a browser:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
USER=&amp;quot;juanrod&amp;quot;&lt;br /&gt;
scp ${USER}@pupil1.healthtech.dtu.dk:/home/people/${USER}/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into your mapping script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for mapping&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;  # Double digestion (relevant for Arima/Phase Genomics)&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1;&lt;br /&gt;
&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --tmpdb ${TMPDIR} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
# &amp;gt;&amp;gt;&amp;gt; Just change the script to take that as a parameter.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; We are not using iterative mapping. Fragment-based mapping is the default in TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Fragment size histogram&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HiC sequencing quality and digestion/ligation deconvolution&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
ref=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# Keep only canonical chromosomes and compress map files after parsing&lt;br /&gt;
tadbit parse \&lt;br /&gt;
       --workdir ${wd} \&lt;br /&gt;
       --genome ${ref} \&lt;br /&gt;
       --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
       --compress_input;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~35 min to complete with 10 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Run filtering:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --tmpdb ${TMPDIR}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Change to workdir&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
# Summarize the run&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# First time we define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Choice of normalization (raw, ICE, Vanilla, decay)&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit normalize -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       --tmpdb ${TMPDIR} \&lt;br /&gt;
       --cpus 6 \&lt;br /&gt;
       --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
       --normalization ${norm} \&lt;br /&gt;
       --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
       --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~2 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⚠️ Run another version with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt; to compare later.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each job is assigned a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;. This helps retrieve results from specific runs (especially when testing parameters).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want, you can take a quick look at the different normalization strategies and extract your own conclusions:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Variables used for binning&lt;br /&gt;
&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
res=&amp;quot;100000&amp;quot;;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit bin \&lt;br /&gt;
       -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       -c ${chrom} \&lt;br /&gt;
       --plot \&lt;br /&gt;
       --norm &amp;quot;norm&amp;quot; \&lt;br /&gt;
       --format &amp;quot;png&amp;quot; \&lt;br /&gt;
       --cpus 6;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=375</id>
		<title>Alignment exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=375"/>
		<updated>2026-01-07T09:22:51Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this mini-workshop you will familiarize yourself with &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt; (Serra et al., 2017):&lt;br /&gt;
from FASTQ files to contact matrix and beyond.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;A Primer into 3D Genomics: A Mini-Workshop&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Juan Antonio Rodríguez, Globe Institute, University of Copenhagen&amp;lt;br&amp;gt;&lt;br /&gt;
9 January 2026, DTU&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use TADbit to:&lt;br /&gt;
    &amp;lt;ol&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Map reads to reference genome (&amp;lt;code&amp;gt;map&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Get intersection (&amp;lt;code&amp;gt;parse&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Filter reads (&amp;lt;code&amp;gt;filter&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Normalize (&amp;lt;code&amp;gt;normalize&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Generate matrices (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Export formats (&amp;lt;code&amp;gt;bin&amp;lt;/code&amp;gt; + &amp;lt;code&amp;gt;cooler&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ol&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit later&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;  # Home folder&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .;&lt;br /&gt;
./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
You should get (as the only output) the help from the program — this means the environment is up and running.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Make yourself familiar with the directory structure. Inside&lt;br /&gt;
&amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; we have three folders:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome raw FASTA and indexed files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before analyzing Hi-C data through TADbit, index the reference genome that GEM mapper will use.&lt;br /&gt;
This is standard for most mappers (e.g., bwa, bowtie2). We can call the &amp;lt;code&amp;gt;gem-indexer&amp;lt;/code&amp;gt;&lt;br /&gt;
from within the TADbit environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Remember to activate the tadbit conda environment.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Move to your home&lt;br /&gt;
cd;&lt;br /&gt;
&lt;br /&gt;
# Activate TADbit environment&lt;br /&gt;
conda activate /home/people/${USER}/envs/tadbit_course&lt;br /&gt;
# $USER is your user; it&#039;s an environment variable so no need to change it.&lt;br /&gt;
&lt;br /&gt;
# Make a WORKING folder for the course&lt;br /&gt;
mkdir -p 3D_GENOMICS_COURSE;&lt;br /&gt;
cd 3D_GENOMICS_COURSE;&lt;br /&gt;
&lt;br /&gt;
# Make SCRIPT folders (to store your own scripts)&lt;br /&gt;
mkdir -p SCRIPTS;&lt;br /&gt;
# also a log folder for the scripts&lt;br /&gt;
mkdir -p SCRIPTS/log&lt;br /&gt;
&lt;br /&gt;
# Make RESULTS folder&lt;br /&gt;
mkdir -p tadbit_dirs;&lt;br /&gt;
&lt;br /&gt;
# Make REFERENCE GENOME folder&lt;br /&gt;
mkdir -p refGenome;&lt;br /&gt;
&lt;br /&gt;
# To store logs from fastp&lt;br /&gt;
mkdir -p fastp_reports&lt;br /&gt;
&lt;br /&gt;
# For the fastq&lt;br /&gt;
mkdir -p fastq&lt;br /&gt;
# Filtered fastq&lt;br /&gt;
mkdir -p fastq/clean&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Putting things into an SBATCH script&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A template for &amp;lt;code&amp;gt;sbatch&amp;lt;/code&amp;gt; job submission is provided. Copy it to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Move to your &amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; folder and make a copy called &amp;lt;code&amp;gt;00_index.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/;&lt;br /&gt;
&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Open the template with your favorite editor, paste the following into the file, and save it.&lt;br /&gt;
For example: &amp;lt;code&amp;gt;emacs 00_index.sbatch&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data_dir=/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE;&lt;br /&gt;
cd ${data_dir};&lt;br /&gt;
&lt;br /&gt;
# Running the indexer&lt;br /&gt;
# Note: the output is just a *prefix*; no file extension needed.&lt;br /&gt;
gem-indexer -t 11 -i refGenome/GCF_000002315.6_GRCg6a_genomic.fna -o /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Submit the job:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch 00_index.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ NO NEED TO RUN THIS. WE WILL GENERATE A SYMBOLIC LINK.&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
We can make a symlink to the reference genome in our folder so that we do not have to copy it:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&lt;br /&gt;
&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna /home/people/${USER}/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5–10 min to complete.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A prepared script is also available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ~/3D_GENOMICS_COURSE/SCRIPTS;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/00_index.sbatch .;&lt;br /&gt;
sbatch 00_index.sbatch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Pre-process Hi-C FASTQ data: minimum QC&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
While genome indexing runs, start looking at the data and pre-process it.&lt;br /&gt;
Hi-C FASTQs are paired-end reads. We will “clean” the reads from adapters,&lt;br /&gt;
low-quality bases, and short reads using &amp;lt;code&amp;gt;fastp&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the template and create &amp;lt;code&amp;gt;01_fastp.sbatch&amp;lt;/code&amp;gt;:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/template.sbatch /home/people/${USER}/3D_GENOMICS_COURSE/SCRIPTS/01_fastp.sbatch;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into the SBATCH script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/fastq&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
FASTQ_DIR=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/fastq&amp;quot;&lt;br /&gt;
&lt;br /&gt;
fastp \&lt;br /&gt;
    # Read raw fastq from course folders&lt;br /&gt;
    -i ${FASTQ_DIR}/${sample}_R1.fastq.gz \&lt;br /&gt;
    # Store the clean fastq version in your folder&lt;br /&gt;
    -o clean/${sample}_R1.clean.fastq.gz \&lt;br /&gt;
    -I ${FASTQ_DIR}/${sample}_R2.fastq.gz \&lt;br /&gt;
    -O clean/${sample}_R2.clean.fastq.gz \&lt;br /&gt;
    --detect_adapter_for_pe \&lt;br /&gt;
    # Trim first 5 bases (often lower quality)&lt;br /&gt;
    --trim_front1 5 \&lt;br /&gt;
    # Threads&lt;br /&gt;
    -w 10 \&lt;br /&gt;
    # Minimal read length (remove reads shorter than this after trimming)&lt;br /&gt;
    -l 30 \&lt;br /&gt;
    -h ${sample}.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Copy the HTML report to your local computer and open it in a browser:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
USER=&amp;quot;juanrod&amp;quot;&lt;br /&gt;
scp ${USER}@pupil1.healthtech.dtu.dk:/home/people/${USER}/3D_GENOMICS_COURSE/fastq/liver.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~1 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Check the HTML report. What percentage of reads are kept?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping to the reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit maps each read separately, so we run &amp;lt;code&amp;gt;tadbit map&amp;lt;/code&amp;gt; twice (once per read).&lt;br /&gt;
It requires the restriction enzyme(s) used in the experiment. These samples were treated with two enzymes.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Put the following into your mapping script:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for mapping&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
ref=&amp;quot;/refGenome/GCF_000002315.6_GRCg6a_genomic.gem&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
mkdir -p ${wd}&lt;br /&gt;
&lt;br /&gt;
# Two enzymes used in this experiment&lt;br /&gt;
enz=&amp;quot;MboI HinfI&amp;quot;  # Double digestion (relevant for Arima/Phase Genomics)&lt;br /&gt;
&lt;br /&gt;
# Map read 1&lt;br /&gt;
rd=1;&lt;br /&gt;
&lt;br /&gt;
tadbit map \&lt;br /&gt;
  --fastq fastq/clean/${sample}_R${rd}.clean.fastq.gz \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --index ${ref} \&lt;br /&gt;
  --read ${rd} \&lt;br /&gt;
  --tmpdb ${TMPDIR} \&lt;br /&gt;
  --renz ${enz} \&lt;br /&gt;
  -C 6&lt;br /&gt;
&lt;br /&gt;
# Map read 2&lt;br /&gt;
rd=2&lt;br /&gt;
# &amp;gt;&amp;gt;&amp;gt; Just change the script to take that as a parameter.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~5 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; We are not using iterative mapping. Fragment-based mapping is the default in TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, inspect the plots TADbit generates. Discuss the number of digested sites,&lt;br /&gt;
dangling ends, and ligation efficiency.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How may restriction enzyme choice influence the experiment? ✂️&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Fragment size histogram&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;HiC sequencing quality and digestion/ligation deconvolution&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Finding the intersection of mapped reads (parse)&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each mate of a Hi-C pair originates from the same digested/ligated fragment (unless it is a dangling end).&lt;br /&gt;
We identify pairs and build fragment associations with &amp;lt;code&amp;gt;tadbit parse&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;⚠️ Note:&amp;lt;/b&amp;gt; The chromosome prefixes to filter have to be defined in the reference genome FASTA file beforehand.&lt;br /&gt;
It will only match chromosomes that start with the string in &amp;lt;code&amp;gt;--filter_chrom&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
ref=&amp;quot;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/refGenome/GCF_000002315.6_GRCg6a_genomic.fna&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# Keep only canonical chromosomes and compress map files after parsing&lt;br /&gt;
tadbit parse \&lt;br /&gt;
       --workdir ${wd} \&lt;br /&gt;
       --genome ${ref} \&lt;br /&gt;
       --filter_chrom &amp;quot;chr.*&amp;quot; \&lt;br /&gt;
       --compress_input;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~35 min to complete with 10 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; Is it possible to retrieve multiple contacting regions?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering interactions&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
TADbit allows flexible filtering of non-wanted interactions. In many cases, the defaults work well across datasets.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Run filtering:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit filter \&lt;br /&gt;
  --workdir ${wd} \&lt;br /&gt;
  --apply 1 2 3 4 6 7 8 9 10 \&lt;br /&gt;
  --cpus 6 \&lt;br /&gt;
  --tmpdb ${TMPDIR}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Check the amount of filtered data and past commands&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; summarizes what has been done so far in the workdir,&lt;br /&gt;
and reports counts, numbers, and parameters after each step.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Change to workdir&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
&lt;br /&gt;
# Summarize the run&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; How many valid pairs do we keep?&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Question:&amp;lt;/b&amp;gt; The total number of filtered reads is not equal to the initial number of reads… Why?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In the filter step we have catalogued all the reads into categories — so it actually didn’t filter anything yet.&lt;br /&gt;
It is during &amp;lt;b&amp;gt;normalization&amp;lt;/b&amp;gt; that we specify which categories to include/exclude so the normalization is performed accordingly.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit extracts a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin) which adjusts interaction intensities&lt;br /&gt;
depending on coverage and technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization is where &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (low counts, low mappability, etc.) are removed from the matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies exist (see: &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt;).&lt;br /&gt;
A simple and commonly used option is to filter based on a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want to exclude specific genomic regions, use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; parameter.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/;&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}  # workdir (auto-created by TADbit)&lt;br /&gt;
&lt;br /&gt;
# First time we define the resolution&lt;br /&gt;
res=&amp;quot;100000&amp;quot;  # 100 kb&lt;br /&gt;
&lt;br /&gt;
# Choice of normalization (raw, ICE, Vanilla, decay)&lt;br /&gt;
norm=&amp;quot;Vanilla&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# Minimum number of counts required per bin&lt;br /&gt;
min_count=100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit normalize -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       --tmpdb ${TMPDIR} \&lt;br /&gt;
       --cpus 6 \&lt;br /&gt;
       --filter 1 2 3 4 6 7 9 10 \&lt;br /&gt;
       --normalization ${norm} \&lt;br /&gt;
       --badcols chrW:1-7000000 chrZ:1-83000000 \&lt;br /&gt;
       --min_count ${min_count}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ It should take ~2 min to complete with 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⚠️ Run another version with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt; to compare later.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use &amp;lt;code&amp;gt;tadbit describe&amp;lt;/code&amp;gt; to check how many bins were removed.&lt;br /&gt;
A good rule of thumb: remove ~3–4% of bins. If much more is removed, something may be wrong.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Each job is assigned a &amp;lt;code&amp;gt;&amp;amp;lt;job_id&amp;amp;gt;&amp;lt;/code&amp;gt;. This helps retrieve results from specific runs (especially when testing parameters).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If you want, you can take a quick look at the different normalization strategies and extract your own conclusions:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
https://www.tandfonline.com/doi/full/10.2144/btn-2019-0105&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Binning and viewing matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Once normalization is done, we can visualize Hi-C matrices. Using &amp;lt;code&amp;gt;-c&amp;lt;/code&amp;gt; restricts the plot to a specific chromosome or region.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Variables used for binning&lt;br /&gt;
&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/&amp;quot;${sample}&lt;br /&gt;
res=&amp;quot;100000&amp;quot;;&lt;br /&gt;
chrom=&amp;quot;chr1&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tadbit bin \&lt;br /&gt;
       -w ${wd} \&lt;br /&gt;
       -r ${res} \&lt;br /&gt;
       -c ${chrom} \&lt;br /&gt;
       --plot \&lt;br /&gt;
       --norm &amp;quot;norm&amp;quot; \&lt;br /&gt;
       --format &amp;quot;png&amp;quot; \&lt;br /&gt;
       --cpus 6;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=374</id>
		<title>Alignment exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=374"/>
		<updated>2026-01-07T09:18:43Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this exercise you will explore Hi-C data analysis using &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt;,&lt;br /&gt;
from raw FASTQ files to normalized contact matrices and domain-level&lt;br /&gt;
interpretation.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The goal is to understand what each step of the pipeline does, which&lt;br /&gt;
parameters matter, and how choices affect downstream interpretation.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index a reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Map reads to the reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Parse and filter read pairs&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Normalize Hi-C contact matrices&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Generate and inspect contact matrices&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before starting, set up a conda environment with all required dependencies.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;   # Home directory&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .&lt;br /&gt;
bash ./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If successful, the command should print the &amp;lt;code&amp;gt;tadbit&amp;lt;/code&amp;gt; help message.&lt;br /&gt;
This confirms that the environment is correctly installed.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Inside &amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; you will find:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw Hi-C FASTQ files&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome FASTA and index files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before mapping Hi-C reads, the reference genome must be indexed for the&lt;br /&gt;
GEM mapper used by TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use the provided reference genome in the &amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; directory.&lt;br /&gt;
This step only needs to be done once per reference.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping Hi-C reads&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Hi-C reads are paired-end and must be mapped with special care to preserve&lt;br /&gt;
pairing information.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Mapping assigns each read to a genomic coordinate in the reference genome.&lt;br /&gt;
Unmapped and ambiguously mapped reads will be handled in later steps.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Parsing mapped reads&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, TADbit parses the BAM file to identify valid Hi-C read pairs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
This step assigns read pairs to different categories (e.g. valid pairs,&lt;br /&gt;
dangling ends, self-circles, duplicates).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering reads&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Filtering does &amp;lt;b&amp;gt;not&amp;lt;/b&amp;gt; remove reads immediately. Instead, reads are&lt;br /&gt;
classified into categories.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
These categories are later used during normalization to decide which&lt;br /&gt;
reads contribute to the contact matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To summarize the results of mapping, parsing, and filtering:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1:&amp;lt;/b&amp;gt; How many valid pairs are retained after filtering?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2:&amp;lt;/b&amp;gt; Why does the total number of filtered reads not equal the&lt;br /&gt;
initial number of read pairs?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Hint: read categories are not mutually exclusive.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Up to this point, reads have only been classified.&lt;br /&gt;
&amp;lt;b&amp;gt;No reads have been excluded yet.&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization is the step where you decide which categories to include&lt;br /&gt;
and how to correct for technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit computes a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin),&lt;br /&gt;
which corrects interaction counts for sequencing depth, mappability, and&lt;br /&gt;
other systematic effects.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;blockquote&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization, &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (bins with low&lt;br /&gt;
counts or poor mappability) are removed from the matrix.&lt;br /&gt;
&amp;lt;/blockquote&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies are available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
See &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt; for details.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A common approach is to require a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;&lt;br /&gt;
and to explicitly exclude problematic genomic regions.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;                  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;      # working directory&lt;br /&gt;
res=&amp;quot;100000&amp;quot;                    # resolution (100 kb)&lt;br /&gt;
norm=&amp;quot;ICE&amp;quot;&lt;br /&gt;
min_count=5&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To exclude specific regions (e.g. sex chromosomes or poorly assembled&lt;br /&gt;
regions), use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; option.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ The normalization step should take approximately 2 minutes using 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Task:&amp;lt;/b&amp;gt; Run normalization twice: once with &amp;lt;code&amp;gt;norm=&amp;quot;ICE&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
and once with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt;. Compare the results later.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Contact matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After normalization, TADbit generates Hi-C contact matrices at the chosen&lt;br /&gt;
resolution.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
These matrices represent interaction frequencies between genomic bins&lt;br /&gt;
and are the basis for downstream analyses such as TAD detection.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3:&amp;lt;/b&amp;gt; How does changing the resolution affect the appearance of the&lt;br /&gt;
contact matrix?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the TADbit exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Postprocess_exercise&amp;diff=373</id>
		<title>Postprocess exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Postprocess_exercise&amp;diff=373"/>
		<updated>2026-01-07T09:13:03Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise, you will perform essential post-alignment processing on BAM files to prepare them for reliable variant calling. Raw aligned BAM files often contain artifacts that can lead to false variants if not handled correctly. Today you will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Mark duplicate reads in BAM files&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Examine the effect of duplicate marking on read interpretation&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Merge multiple sequencing libraries from the same individual into a single BAM file&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;postalign&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Enter the &amp;lt;code&amp;gt;postalign&amp;lt;/code&amp;gt; directory&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Duplicate Marking&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will work with data from a Han Chinese individual (HG00418), sequenced to approximately 40× coverage using Illumina paired-end sequencing. For speed, we only use reads mapping to chromosome 20 and only two sequencing libraries.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Library 1 BAM file:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/dupremoval/ERR016028_chr20_sort.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The file is already trimmed, aligned, and sorted.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will mark duplicate reads using &amp;lt;b&amp;gt;Picard MarkDuplicates&amp;lt;/b&amp;gt;. The general command is:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
java -jar /home/ctools/picard_2.23.8/picard.jar MarkDuplicates \&lt;br /&gt;
    -I [input.bam] \&lt;br /&gt;
    -M [metrics.txt (this is part of the output, call it what you wish)] \&lt;br /&gt;
    -O [output.bam]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Suggested output name: &amp;lt;code&amp;gt;ERR016028_chr20_sort_markdup.bam&amp;lt;/code&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1:&amp;lt;/b&amp;gt; After running Picard, how many reads were marked as duplicates?  &lt;br /&gt;
(Hint: this number is printed in the Picard metrics output file.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Inspecting the Effect of Duplicate Marking&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To view reads in a specific genomic region, use:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view [input.sorted.bam] [chrom]:[start]-[end]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The BAM file must be indexed. Picard preserves sorting, so you do not need to re-sort it.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Inspect reads in the following region for both the &amp;lt;b&amp;gt;original file&amp;lt;/b&amp;gt; and your &amp;lt;b&amp;gt;duplicate-marked file&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:45996339-45996839&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Identify the two reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;ERR016028.5947720&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;ERR016028.18808080&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2:&amp;lt;/b&amp;gt; Why did MarkDuplicates consider these reads to be duplicates?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3:&amp;lt;/b&amp;gt; Which of the two reads was marked as a duplicate, and how can you tell from the SAM flag or tags?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Merging BAM Files&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Often, multiple sequencing libraries (or sequencing runs) exist for the same biological sample. Before variant calling, these must be merged into a single BAM file.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You will merge:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Your duplicate-marked file&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;The second library file:&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/dupremoval/ERR016025_chr20_sort_markdup.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;samtools&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;and find the command capable of merging multiple BAM files while preserving read groups and writing an index automatically. The command should keep the file sorted and generate the &amp;lt;code&amp;gt;.bai&amp;lt;/code&amp;gt; index in the same step.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4:&amp;lt;/b&amp;gt; Which &amp;lt;code&amp;gt;samtools&amp;lt;/code&amp;gt; command performs merging, with options to keep read groups and write the index?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the options:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
-c   --write-index&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Your merged BAM file should be named:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
HG00418_chr20_sort_markdup.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Inspect your merged file using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view HG00418_chr20_sort_markdup.bam | less -S&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5:&amp;lt;/b&amp;gt; Which SAM/BAM field indicates the sample or library of origin for each read?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6:&amp;lt;/b&amp;gt; What is the term for pooling multiple samples together into a single sequencing run?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7:&amp;lt;/b&amp;gt; What is the computational step where we separate pooled reads back into individual samples?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can find the answers here: &amp;lt;a href=&amp;quot;Postprocess_exercise_answers&amp;quot;&amp;gt;Postprocess_exercise_answers&amp;lt;/a&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations—you have completed the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_part_1&amp;diff=372</id>
		<title>SNP calling exercise part 1</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=SNP_calling_exercise_part_1&amp;diff=372"/>
		<updated>2026-01-07T09:11:02Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise you will perform basic variant calling and start exploring VCF files. You will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run a germline variant caller on whole-genome sequencing data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Get acquainted with VCF and gVCF formats&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Count and subset variants using command-line tools&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Compare “known” vs “novel” variants&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;variant_call&amp;lt;/code&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Enter the &amp;lt;code&amp;gt;variant_call&amp;lt;/code&amp;gt; directory&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Genotyping&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will genotype chromosome 20 from a BAM file that has been pre-processed (sorted, duplicate-marked, etc.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The sample is a [https://en.wikipedia.org/wiki/Han_Chinese Han Chinese] male, sequenced to approximately 24.6x coverage.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/snp_calling/NA24694.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The BAM file is already indexed.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use &amp;lt;b&amp;gt;GATK HaplotypeCaller&amp;lt;/b&amp;gt; to generate a gVCF file. A typical command looks like this:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk --java-options &amp;quot;-Xmx10g&amp;quot; HaplotypeCaller \&lt;br /&gt;
    -R /home/databases/references/human/GRCh38_full_analysis_set_plus_decoy_hla.fa \&lt;br /&gt;
    -I [INPUT_BAM] \&lt;br /&gt;
    -L chr20 \&lt;br /&gt;
    -O [OUTPUT_GVCF] \&lt;br /&gt;
    --dbsnp /home/databases/databases/GRCh38/Homo_sapiens_assembly38.dbsnp138.vcf.gz \&lt;br /&gt;
    -ERC GVCF&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Explanation of the key options:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-R&amp;lt;/code&amp;gt; – reference genome (GRCh38)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-I&amp;lt;/code&amp;gt; – input BAM file (here: &amp;lt;code&amp;gt;NA24694.bam&amp;lt;/code&amp;gt;)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-L chr20&amp;lt;/code&amp;gt; – restrict calling to chromosome 20&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;--dbsnp&amp;lt;/code&amp;gt; – annotate with known variants from dbSNP&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;-ERC GVCF&amp;lt;/code&amp;gt; – emit a gVCF (includes both variant and non-variant blocks)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Suggested output name:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NA24694.gvcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This command may take a while to complete. If you are short on time, you can use the precomputed file instead:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/snp_calling/NA24694.gvcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Take a quick look at the gVCF:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat NA24694.gvcf.gz | less -S&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Notes:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Lines starting with &amp;lt;code&amp;gt;#&amp;lt;/code&amp;gt; form the header.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Data lines have at least 10 columns. The first five are:&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;CHROM – chromosome name&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;POS – genomic coordinate&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;ID – variant identifier (e.g. dbSNP ID, or &amp;lt;code&amp;gt;.&amp;lt;/code&amp;gt; if unknown)&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;REF – reference allele&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;ALT – alternate allele(s)&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;In gVCFs, you will often see &amp;lt;code&amp;gt;&amp;amp;lt;NON_REF&amp;amp;gt;&amp;lt;/code&amp;gt; as the ALT allele for invariant blocks.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Indexing the gVCF&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Before using the gVCF as input for other tools, index it with &amp;lt;b&amp;gt;tabix&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix -f -p vcf [INPUT_GVCF]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This creates an index file with extension &amp;lt;code&amp;gt;.tbi&amp;lt;/code&amp;gt;, allowing fast random access by position.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Genotyping the gVCF (producing a standard VCF)&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we convert the gVCF into a standard VCF with genotypes only at variant sites using &amp;lt;b&amp;gt;GATK GenotypeGVCFs&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/gatk-4.6.2.0/gatk GenotypeGVCFs \&lt;br /&gt;
    -R /home/databases/references/human/GRCh38_full_analysis_set_plus_decoy_hla.fa \&lt;br /&gt;
    -V [INPUT_GVCF] \&lt;br /&gt;
    -O [OUTPUT_VCF] \&lt;br /&gt;
    -L chr20 \&lt;br /&gt;
    --dbsnp /home/databases/databases/GRCh38/Homo_sapiens_assembly38.dbsnp138.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Suggested output name:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NA24694.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;This step is usually faster than HaplotypeCaller.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the VCF with tabix:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix -f -p vcf NA24694.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;As with BAM indices, the VCF index allows fast region-based queries, but here using tabix rather than samtools.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Getting Acquainted with VCF Files&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1.&amp;lt;/b&amp;gt; Using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bcftools stats [INPUT_VCF]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Find the line that starts with:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SN    0    number of SNPs&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;How many SNPs are present in your VCF?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can query specific regions of the VCF using tabix:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix [INPUT_VCF] [CHROM]:[START]-[END]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;For a single coordinate:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix [INPUT_VCF] [CHROM]:[POS]-[POS]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2.&amp;lt;/b&amp;gt; Using tabix and &amp;lt;code&amp;gt;wc -l&amp;lt;/code&amp;gt;, how many total variants are present in the 1 Mb region:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:32000000-33000000&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;(Remember that tabix only returns data lines, so you can safely count lines with &amp;lt;code&amp;gt;wc -l&amp;lt;/code&amp;gt;.)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3.&amp;lt;/b&amp;gt; &amp;lt;code&amp;gt;bcftools&amp;lt;/code&amp;gt; can subset and filter VCF files.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Type:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bcftools view&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;and look at the help text. Using &amp;lt;code&amp;gt;bcftools view&amp;lt;/code&amp;gt;, determine how many &amp;lt;b&amp;gt;SNPs&amp;lt;/b&amp;gt; (excluding indels and multi-allelic variants) are present in the &amp;lt;b&amp;gt;same region&amp;lt;/b&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:32000000-33000000&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Hints:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Filter for variant type (SNPs only).&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Use &amp;lt;code&amp;gt;-H&amp;lt;/code&amp;gt; to avoid counting header lines.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Pipe the result to &amp;lt;code&amp;gt;wc -l&amp;lt;/code&amp;gt; to count variants.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4.&amp;lt;/b&amp;gt; Retrieve the variants at:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:32011209&lt;br /&gt;
chr20:32044279&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You can use either tabix or bcftools, for example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/htslib-1.20/tabix NA24694.vcf.gz chr20:32011209-32011209&lt;br /&gt;
/home/ctools/htslib-1.20/tabix NA24694.vcf.gz chr20:32044279-32044279&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;For each site, answer:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What is the genotype (e.g. 0/0, 0/1, 1/1)?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What is the allele depth (AD) – how many reads support each allele?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What is the total depth of coverage (DP) at this site?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What is the genotype quality (GQ)?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What are the genotype likelihoods (PL)?&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the VCF specification (&amp;lt;a href=&amp;quot;https://samtools.github.io/hts-specs/VCFv4.2.pdf&amp;quot;&amp;gt;VCFv4.2&amp;lt;/a&amp;gt;, especially section 1.4 “Data lines”) and GATK’s VCF documentation (&amp;lt;a href=&amp;quot;https://gatk.broadinstitute.org/hc/en-us/articles/360035531692-VCF-Variant-Call-Format&amp;quot;&amp;gt;GATK VCF Format&amp;lt;/a&amp;gt;) to interpret the FORMAT fields.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5.&amp;lt;/b&amp;gt; Inspect the SNPs at positions:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20    32974911&lt;br /&gt;
chr20    64291638&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;One of these SNPs has poor quality, the other has good quality.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Which is which?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Why do you think this is the case? (Hint: think about depth, allele balance, and overall evidence.)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6.&amp;lt;/b&amp;gt; Using the same region as in Q2/Q3:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chr20:32000000-33000000&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;How many SNPs in this region are &amp;lt;b&amp;gt;novel&amp;lt;/b&amp;gt;, i.e. do not have an ID in dbSNP?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Hints:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;The 3rd column (ID) contains dbSNP IDs (typically starting with &amp;lt;code&amp;gt;rs&amp;lt;/code&amp;gt;) or &amp;lt;code&amp;gt;.&amp;lt;/code&amp;gt; for novel variants.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;You can use &amp;lt;code&amp;gt;cut&amp;lt;/code&amp;gt; to extract the ID column.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;grep&amp;lt;/code&amp;gt; with &amp;lt;code&amp;gt;-v&amp;lt;/code&amp;gt; can be used to exclude lines containing &amp;lt;code&amp;gt;rs&amp;lt;/code&amp;gt;, or to include only those lines.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7.&amp;lt;/b&amp;gt; Compare your result from Q6 (number of novel SNPs) to the number of SNPs you found in Q3 (total SNPs in the region).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;What fraction of SNPs in this region are novel?&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Does this fraction seem reasonable, given that human variation databases are large but still incomplete?&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=366</id>
		<title>Alignment exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Alignment_exercise&amp;diff=366"/>
		<updated>2026-01-06T14:53:03Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
In this exercise you will explore Hi-C data analysis using &amp;lt;b&amp;gt;TADbit&amp;lt;/b&amp;gt;,&lt;br /&gt;
from raw FASTQ files to normalized contact matrices and domain-level&lt;br /&gt;
interpretation.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
The goal is to understand what each step of the pipeline does, which&lt;br /&gt;
parameters matter, and how choices affect downstream interpretation.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Outline of the exercises&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Preprocess Hi-C FASTQ data&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Index a reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Map reads to the reference genome&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Parse and filter read pairs&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Normalize Hi-C contact matrices&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Generate and inspect contact matrices&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Setup conda environment to run TADbit&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before starting, set up a conda environment with all required dependencies.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd;   # Home directory&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE/SCRIPTS/setup_TADbit.sh .&lt;br /&gt;
./setup_TADbit.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
If successful, the command should print the &amp;lt;code&amp;gt;tadbit&amp;lt;/code&amp;gt; help message.&lt;br /&gt;
This confirms that the environment is correctly installed.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Inside &amp;lt;code&amp;gt;/home/projects/22126_NGS/exercises/3D_GENOMICS_COURSE&amp;lt;/code&amp;gt; you will find:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;fastq&amp;lt;/code&amp;gt; – raw Hi-C FASTQ files&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;SCRIPTS&amp;lt;/code&amp;gt; – scripts to run TADbit&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; – reference genome FASTA and index files&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Index reference genome&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Before mapping Hi-C reads, the reference genome must be indexed for the&lt;br /&gt;
GEM mapper used by TADbit.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Use the provided reference genome in the &amp;lt;code&amp;gt;refGenome&amp;lt;/code&amp;gt; directory.&lt;br /&gt;
This step only needs to be done once per reference.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Mapping Hi-C reads&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Hi-C reads are paired-end and must be mapped with special care to preserve&lt;br /&gt;
pairing information.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Mapping assigns each read to a genomic coordinate in the reference genome.&lt;br /&gt;
Unmapped and ambiguously mapped reads will be handled in later steps.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Parsing mapped reads&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After mapping, TADbit parses the BAM file to identify valid Hi-C read pairs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
This step assigns read pairs to different categories (e.g. valid pairs,&lt;br /&gt;
dangling ends, self-circles, duplicates).&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Filtering reads&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Filtering does &amp;lt;b&amp;gt;not&amp;lt;/b&amp;gt; remove reads immediately. Instead, reads are&lt;br /&gt;
classified into categories.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
These categories are later used during normalization to decide which&lt;br /&gt;
reads contribute to the contact matrix.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To summarize the results of mapping, parsing, and filtering:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/tadbit_dirs/$sample&lt;br /&gt;
tadbit describe . | less&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1:&amp;lt;/b&amp;gt; How many valid pairs are retained after filtering?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2:&amp;lt;/b&amp;gt; Why does the total number of filtered reads not equal the&lt;br /&gt;
initial number of read pairs?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Hint: read categories are not mutually exclusive.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;To normalize or to not normalize&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Up to this point, reads have only been classified.&lt;br /&gt;
&amp;lt;b&amp;gt;No reads have been excluded yet.&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization is the step where you decide which categories to include&lt;br /&gt;
and how to correct for technical biases.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Normalization in TADbit computes a &amp;lt;b&amp;gt;bias vector&amp;lt;/b&amp;gt; (one value per bin),&lt;br /&gt;
which corrects interaction counts for sequencing depth, mappability, and&lt;br /&gt;
other systematic effects.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;blockquote&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Important:&amp;lt;/b&amp;gt; During normalization, &amp;lt;b&amp;gt;bad columns&amp;lt;/b&amp;gt; (bins with low&lt;br /&gt;
counts or poor mappability) are removed from the matrix.&lt;br /&gt;
&amp;lt;/blockquote&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Several normalization strategies are available:&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
See &amp;lt;code&amp;gt;tadbit normalize --help&amp;lt;/code&amp;gt; for details.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
A common approach is to require a &amp;lt;b&amp;gt;minimum number of counts per bin&amp;lt;/b&amp;gt;&lt;br /&gt;
and to explicitly exclude problematic genomic regions.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /home/people/$USER/3D_GENOMICS_COURSE/&lt;br /&gt;
&lt;br /&gt;
# Variables used for normalization&lt;br /&gt;
sample=&amp;quot;liver&amp;quot;                  # sample name&lt;br /&gt;
wd=&amp;quot;tadbit_dirs/${sample}&amp;quot;      # working directory&lt;br /&gt;
res=&amp;quot;100000&amp;quot;                    # resolution (100 kb)&lt;br /&gt;
norm=&amp;quot;ICE&amp;quot;&lt;br /&gt;
min_count=5&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
To exclude specific regions (e.g. sex chromosomes or poorly assembled&lt;br /&gt;
regions), use the &amp;lt;code&amp;gt;--badcols&amp;lt;/code&amp;gt; option.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
⏰ The normalization step should take approximately 2 minutes using 6 CPUs.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Task:&amp;lt;/b&amp;gt; Run normalization twice: once with &amp;lt;code&amp;gt;norm=&amp;quot;ICE&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
and once with &amp;lt;code&amp;gt;norm=&amp;quot;raw&amp;quot;&amp;lt;/code&amp;gt;. Compare the results later.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;Contact matrices&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
After normalization, TADbit generates Hi-C contact matrices at the chosen&lt;br /&gt;
resolution.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
These matrices represent interaction frequencies between genomic bins&lt;br /&gt;
and are the basis for downstream analyses such as TAD detection.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3:&amp;lt;/b&amp;gt; How does changing the resolution affect the appearance of the&lt;br /&gt;
contact matrix?&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the TADbit exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=365</id>
		<title>Program 2026</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Program_2026&amp;diff=365"/>
		<updated>2026-01-06T14:36:36Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&#039;&#039;&#039;NOTE: THIS PAGE IS UNDER CONSTRUCTION WITH A NEW TEACHER IN 2026&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;REMEMBER TO BRING A LAPTOP FOR EXERCISES&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures will be in person in building [https://maps.app.goo.gl/wH5EW199wrChCmWK7 341] in auditorium 23. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Lectures and exercises will take place on Discord (https://discord.gg/Qgw9M3SZA5). Please register with your full name. Will use Discord for online classes and collaboration with your project partners. Rather than emailing questions to the teaching staff, I encourage you to post your questions on discord.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The course has two main parts, the first half is lectures and exercises and the last half is project work ending with the exam on &#039;&#039;&#039;Friday 23rd of January 2026&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;For the laptop &#039;&#039;&#039; if you have a secure laptop (e.g. work laptop from Statens Serum Institut for instance), please bring your personal laptop.&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
=== Course Program - January 2026 ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 5 (Day 1)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Introduction - Next Generation Sequencing&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to course &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-1-Intro.pdf Lecture slides])&lt;br /&gt;
&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;dd&amp;gt;Introduction to NGS &lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-2-NGS_basics.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-10:45am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;The NGS revolution&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_1-3-NGS_revolution.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:45am-11:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;11:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Logging on to our pupil servers ([[Logging on to pupil system]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury , Amanda Gammelby Qvesel, Mads Hartmann  &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-2:15pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-2:30pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-3:30pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Introduction to UNIX (continued)&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;([https://teaching.healthtech.dtu.dk/22113/index.php/Unix Video lectures to watch from &amp;quot;Unix intro..&amp;quot; to &amp;quot;Touching upon...&amp;quot;])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;([[Unix Exercises|Unix exercises]] – possible answers [[Unix_answers|here]])&lt;br /&gt;
([[Basic UNIX notes]])&lt;br /&gt;
([[Advanced UNIX and Pipes]])&amp;lt;/DD&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;3:30pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;First look at data&lt;br /&gt;
([[First look exercise]])&lt;br /&gt;
&amp;lt;DD&amp;gt;Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 6 (Day 2)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Data pre-processing &amp;amp; Alignment&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data basics ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-1-Data_basics.pdf Lecture slides]) ([[Data basics exercise]]) ([[Data basics exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Data pre-processing ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-2-QC_preprocessing.pdf Lecture slides]) ([[Data Preprocess exercise]]) ([[Data Preprocess exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm  &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Alignment ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_2-3-Alignment.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Alignment ([[Alignment exercise]]) ([[Alignment exercise answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 7 (Day 3)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Variant calling &#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Functional Variation&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-1-Functional_variation.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:30am-10:15am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Variant calling part 1 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-2-Preprocessing-variant_calling.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15am-10:30am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:30am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Preprocessing ([[Postprocess exercise]])  ([[Postprocess_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 1 ([[SNP calling exercise part 1]]) ([[SNP_calling_exercise_answers part 1]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: variant calling part 2 ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_3-3-Variant_filtering.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: variant calling part 2 ([[SNP calling exercise part 2]]) ([[SNP_calling_exercise_answers part 2]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 8 (Day 4)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Assembly, annotation and RNA-seq&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: de novo assembly and genomic annotations ([https://teaching.healthtech.dtu.dk/material/22126/2026/Lecture_4-1-Denovo.pdf Lecture slides]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: de novo assembly ([[denovo exercise]]) ([[denovo solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: RNAseq ([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_without_solutions_v2.pdf Lecture slides]) &lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&lt;br /&gt;
([https://teaching.healthtech.dtu.dk/material/22126/2024/ngs_transcriptomics_kvs_2023_with_solutions_v2.pdf Lecture slides with solutions])&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: RNAseq ([[Rnaseq_exercise]]) &amp;lt;!-- ([[Rnaseq_exercise_answers]]) --&amp;gt; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Kristoffer Vitting-Seerup, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 9 (Day 5)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Ancient DNA and 3D genomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-10:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Ancient DNA ([https://teaching.healthtech.dtu.dk/material/22126/2025/dtu_adna_2025_red.pdf Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00pm-10:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:15pm-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: Ancient DNA ([[Ancient DNA exercise]]) ([[Ancient_DNA_exercise_answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Martin Sikora, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-2:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: 3D Genomics with Hi-C ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Juan Rodríguez&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00am-2:15pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:15pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: 3D Genomics with Hi-C ([[Exercise and answers]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Juan Rodríguez, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 12 (Day 6)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Microbial genomics&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:45am &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:45am-10:00am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[ Microbial_genomics_exercise ]]) ([[ solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([ Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Questions]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Rasmus Lykke Marvig, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 13 (Day 7)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Phylogenomics&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercise]]) ([[Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Lecture: TBA ([Lecture slides])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:00pm-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Exercises]]) ([[Solution]]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;David Duchene, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 14 (Day 8)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Metabarcoding and group project&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-9:55am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;TBA ([ Lecture])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;9:55am-10:10am&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:10am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Exercise: TBA ([[Metabarcoding Exercise]]) ([[Metabarcoding Solution]])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Luke Holman&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039; &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-1:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt; Recap Test ([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024.pdf Test 2025])([https://teaching.healthtech.dtu.dk/material/22126/2024/test_2024_withA.pdf answers])&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann &amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:30pm-1:45pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:45pm-2:30pm &amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation ([https://teaching.healthtech.dtu.dk/material/22126/2026/Poster.pdf Lecture slides] [http://teaching.healthtech.dtu.dk/material/22126/2023/posters.tar.gz Examples from previous courses]) &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;2:30pm-4:00pm &amp;lt;/DT&amp;gt;  &lt;br /&gt;
&amp;lt;DD&amp;gt;Projects &amp;amp; Group formation, prepare an outline for tomorrow. please write group names in the [https://docs.google.com/document/d/1W5HzThk4zSi2xAE4dwmtgw35JtyNbwhuizseiLrxLr0/edit?usp=sharing document for 2026]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 15 (Day 9)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt; &lt;br /&gt;
&amp;lt;DD&amp;gt;Project consolation, check when your 3 minutes are [https://docs.google.com/spreadsheets/d/1eZeAo0jtpUcJpd7ti8h2ofjVJD8wYOUws9QMZwp0fQ8/edit?usp=sharing Timesheet]&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;DD&amp;gt;You can go to Discord for help, we will be available.&amp;lt;/DD&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;12:00pm-1:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;&#039;&#039;Lunch Break&#039;&#039;&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-4:00pm &amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project &amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 16 (Day 10)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Monday, January 19 (Day 11)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tuesday, January 20 (Day 12)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Wednesday, January 21 (Day 13)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project work&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work&amp;lt;/DD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;1:00pm-3:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Thursday, January 22 (Day 14)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Project Work &amp;amp; Submit poster&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;DT&amp;gt;10:00am-12:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Q&amp;amp;A: Practical information about the exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Project work/Office hours&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt; Mick Westbury, Amanda Gammelby Qvesel, Mads Hartmann&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Friday, January 23 (Day 15)&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;HR&amp;gt;&lt;br /&gt;
&#039;&#039;Exam&#039;&#039;&lt;br /&gt;
&amp;lt;DL&amp;gt;&lt;br /&gt;
&amp;lt;DT&amp;gt;9:00am-4:00pm&amp;lt;/DT&amp;gt;&lt;br /&gt;
&amp;lt;DD&amp;gt;Written Exam&amp;lt;/DD&amp;gt;&lt;br /&gt;
&amp;lt;/DL&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=362</id>
		<title>Denovo exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=362"/>
		<updated>2026-01-06T13:43:22Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to the directory you just created.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise we will perform a &amp;lt;b&amp;gt;de novo assembly&amp;lt;/b&amp;gt; of Illumina paired-end reads. The data is from a &amp;lt;i&amp;gt;Vibrio cholerae&amp;lt;/i&amp;gt; strain isolated in Nepal. You will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run FastQC and perform adapter/quality trimming (optional recap of pre-processing).&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Count k-mers and estimate genome size.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Correct reads using Musket.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Determine insert size of paired-end reads.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run de novo assembly using MEGAHIT.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Calculate assembly statistics.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Plot coverage and length histograms of the assembly.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Evaluate the assembly quality.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Visualize the assembly using Circoletto.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;(Bonus) Try assembling the genome with SPAdes.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Annotation of a prokaryotic genome.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;FastQC and trimming&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Make sure you are in the &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt; directory you created. You can double-check with:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pwd&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the sequencing data:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/* .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run FastQC on the reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing FastQC HTML reports:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the FastQC HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_1_sequence_fastqc.html .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_2_sequence_fastqc.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;There are several issues with this dataset (you do not need to study the report in detail now). We will clean it up first. Let’s identify the quality encoding:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_detect_fq.sh Vchol-001_6_1_sequence.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1. Which quality encoding format is used?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Trim the reads using AdapterRemoval. The most frequent adapter/primer sequences are already included below. We use a minimum read length of 40 nt, trim to quality 20, and specify quality base 64. The &amp;lt;code&amp;gt;--basename&amp;lt;/code&amp;gt; option defines the output prefix and &amp;lt;code&amp;gt;--gzip&amp;lt;/code&amp;gt; compresses the output.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/adapterremoval-2.3.4/build/AdapterRemoval \&lt;br /&gt;
  --file1 Vchol-001_6_1_sequence.txt.gz \&lt;br /&gt;
  --file2 Vchol-001_6_2_sequence.txt.gz \&lt;br /&gt;
  --adapter1 GATCGGAAGAGCACACGTCTGAACTCCAGTCACATCACGATATCGTATGC \&lt;br /&gt;
  --adapter2 GATCGGAAGAGCGTCGTGTAGGGAAAGAGGGTAGATCTCGGTGGTCGCCG \&lt;br /&gt;
  --qualitybase 64 \&lt;br /&gt;
  --basename Vchol-001_6 \&lt;br /&gt;
  --gzip \&lt;br /&gt;
  --trimqualities \&lt;br /&gt;
  --minquality 20 \&lt;br /&gt;
  --minlength 40&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When it finishes, inspect &amp;lt;code&amp;gt;Vchol-001_6.settings&amp;lt;/code&amp;gt; for trimming statistics (how many reads were trimmed, discarded, etc.).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1A. The output includes &amp;lt;code&amp;gt;discarded.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair1.truncated.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair2.truncated.gz&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;singleton.truncated.gz&amp;lt;/code&amp;gt;. What types of reads does each file contain? (Tip: check the AdapterRemoval documentation.)&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, compute basic read stats (average read length, min/max length, number of reads, total bases) for the trimmed paired reads. Note down the average read length and total number of bases:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair1.truncated.gz&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair2.truncated.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Genome size estimation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will count k-mers in the data. A k-mer is simply a DNA word of length k. We use &amp;lt;b&amp;gt;jellyfish&amp;lt;/b&amp;gt; to count 15-mers. We combine counts from forward and reverse-complement strands and then create a histogram. (This may take some time to run so could be good time to practice using &amp;quot;screen&amp;quot;)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Manual: [http://www.cbcb.umd.edu/software/jellyfish/jellyfish-manual.html jellyfish]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip -dc Vchol-001_6.pair*.truncated.gz \&lt;br /&gt;
  | /home/ctools/jellyfish-2.3.1/bin/jellyfish count -t 2 -m 15 -s 1000000000 -o Vchol-001 -C /dev/fd/0&lt;br /&gt;
&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish histo Vchol-001 &amp;gt; Vchol-001.histo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;Vchol-001.histo&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;Vchol-001.histo.pdf&amp;quot;)&lt;br /&gt;
barplot(dat[,2],&lt;br /&gt;
        xlim = c(0,150),&lt;br /&gt;
        ylim = c(0,5e5),&lt;br /&gt;
        ylab = &amp;quot;No of kmers&amp;quot;,&lt;br /&gt;
        xlab = &amp;quot;Counts of a k-mer&amp;quot;,&lt;br /&gt;
        names.arg = dat[,1],&lt;br /&gt;
        cex.names = 0.8)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the pdf files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/Vchol-001.histo.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The plot shows:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;x-axis: how many times a k-mer occurs (its count)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;y-axis: number of distinct k-mers with that count&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;K-mers that occur only a few times are typically due to sequencing errors. K-mers forming the main peak (higher counts) are likely “real” and can be used for error correction and genome size estimation.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2. Where is the k-mer coverage peak (approximately)?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We can estimate genome size using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
N = (M * L) / (L - K + 1)&lt;br /&gt;
Genome_size = T / N&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;N&amp;lt;/b&amp;gt; = depth (coverage)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;M&amp;lt;/b&amp;gt; = k-mer peak (from the histogram)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;K&amp;lt;/b&amp;gt; = k-mer size (here: 15)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;L&amp;lt;/b&amp;gt; = average read length (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;T&amp;lt;/b&amp;gt; = total number of bases (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute the estimated genome size and compare with the known &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome (~4 Mb). You should be within roughly ±10%.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3. What is your estimated genome size?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Error correction&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will correct errors in the reads using &amp;lt;b&amp;gt;Musket&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Musket: [http://musket.sourceforge.net/homepage.htm Musket]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, get the number of distinct k-mers (needed for memory allocation in Musket):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish stats Vchol-001&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the reported number of distinct k-mers (here an example: &amp;lt;code&amp;gt;8423098&amp;lt;/code&amp;gt;) in the Musket command:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/musket-1.1/musket -k 15 8423098 -p 1 -omulti Vchol-001_6.cor -inorder \&lt;br /&gt;
  Vchol-001_6.pair1.truncated.gz Vchol-001_6.pair2.truncated.gz -zlib 1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output files are named &amp;lt;code&amp;gt;Vchol-001_6.cor.0&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;Vchol-001_6.cor.1&amp;lt;/code&amp;gt;. Rename them:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mv Vchol-001_6.cor.0 Vchol-001_6.pair1.cor.truncated.fq.gz&lt;br /&gt;
mv Vchol-001_6.cor.1 Vchol-001_6.pair2.cor.truncated.fq.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;If this takes too long, you can copy precomputed corrected reads:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/corrected/Vchol-001_6.pair*.cor.truncated.fq.gz .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;&amp;lt;i&amp;gt;De novo&amp;lt;/i&amp;gt; assembly with MEGAHIT&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now assemble the corrected reads using &amp;lt;b&amp;gt;MEGAHIT&amp;lt;/b&amp;gt; (a de Bruijn graph assembler). K-mer size is critical: MEGAHIT can test multiple k-mers by default, but here we start with a fixed k-mer size of 35.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, set the number of threads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run MEGAHIT with k=35:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list 35 \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o 35&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When finished, you should have &amp;lt;code&amp;gt;35/final.contigs.fa&amp;lt;/code&amp;gt;. Compress it:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip 35/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To estimate insert size, we will map a subset of reads back to the assembly (similar to the alignment exercise). We’ll subsample the first 100,000 read pairs (400,000 lines per FASTQ):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat Vchol-001_6.pair1.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_1.fastq&lt;br /&gt;
zcat Vchol-001_6.pair2.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_2.fastq&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the assembly and map:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bwa index 35/final.contigs.fa.gz&lt;br /&gt;
&lt;br /&gt;
bwa mem 35/final.contigs.fa.gz Vchol_sample_1.fastq Vchol_sample_2.fastq \&lt;br /&gt;
  | samtools view -Sb - &amp;gt; Vchol_35bp.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract insert sizes (TLEN field, column 9):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view Vchol_35bp.bam | cut -f9 &amp;gt; initial.insertsizes.txt&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
a   = read.table(&amp;quot;initial.insertsizes.txt&amp;quot;)&lt;br /&gt;
a.v = a[a[,1] &amp;gt; 0, 1]&lt;br /&gt;
mn  = quantile(a.v, seq(0,1,0.05))[4]&lt;br /&gt;
mx  = quantile(a.v, seq(0,1,0.05))[18]&lt;br /&gt;
mean(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])   # mean insert size&lt;br /&gt;
sd(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])     # standard deviation&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4. What are the mean insert size and standard deviation of the library?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we will explore different k-mer sizes. Each student chooses a different k-mer from this Google sheet:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://docs.google.com/spreadsheets/d/1trUMlSwNLoNW67D-OkgA93iOQRp2iioyJSBYyW30P4U/edit?usp=sharing Google sheet for k-mer assignment]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Write your name next to the k-mer you select, then run MEGAHIT with that k-mer, replacing &amp;lt;code&amp;gt;[KMER]&amp;lt;/code&amp;gt; below:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list [KMER] \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o [KMER]&lt;br /&gt;
&lt;br /&gt;
gzip [KMER]/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute assembly statistics using &amp;lt;code&amp;gt;QUAST&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
 [KMER]/final.contigs.fa.gz \&lt;br /&gt;
 --threads 1 \&lt;br /&gt;
 -o [KMER]/quast&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the file &amp;lt;code&amp;gt;[KMER]/quast/report.txt&amp;lt;/code&amp;gt; (or &amp;lt;code&amp;gt;report.tsv&amp;lt;/code&amp;gt;) and&lt;br /&gt;
record the following values in the Google sheet for your k-mer:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Number of contigs (&amp;amp;ge; 500 bp)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Total assembly length&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Largest contig&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;N50&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;As a class, compare results across k-mer sizes and discuss which k-mer produces&lt;br /&gt;
the most reasonable assembly and why.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the best assembly to your folder, or use a precomputed multi-k assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.fa.gz .&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.stats .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5. How does the N50 of the best assembly (multi-k or default) compare to the N50 from the fixed-k assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6. How does the longest contig length compare between fixed-k and multi-k/default assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Coverage of the assembly&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now calculate per-contig coverage and lengths, and visualize them in R.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat default_final.contigs.fa.gz | /home/ctools/bin/fastx_megahit.sh --i /dev/stdin &amp;gt; default_finalt.cov&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(plotrix)&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;default_finalt.cov&amp;quot;, sep = &amp;quot;\t&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
## ---- Coverage plots (2 panels) ----&lt;br /&gt;
pdf(&amp;quot;best.coverage.pdf&amp;quot;, width = 10, height = 5)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
&lt;br /&gt;
weighted.hist(w = dat[,2],&lt;br /&gt;
              x = dat[,1],&lt;br /&gt;
              breaks = seq(0, 100, 1),&lt;br /&gt;
              main = &amp;quot;Weighted coverage&amp;quot;,&lt;br /&gt;
              xlab = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
hist(dat[,1],&lt;br /&gt;
     xlim   = c(0, 100),&lt;br /&gt;
     breaks = seq(0, 1000, 1),&lt;br /&gt;
     main   = &amp;quot;Raw coverage&amp;quot;,&lt;br /&gt;
     xlab   = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&lt;br /&gt;
## ---- Scaffold lengths (1 panel) ----&lt;br /&gt;
pdf(&amp;quot;scaffold.lengths.pdf&amp;quot;, width = 7, height = 5)&lt;br /&gt;
par(mfrow = c(1, 1))&lt;br /&gt;
&lt;br /&gt;
barplot(rev(sort(dat[,2])),&lt;br /&gt;
        xlab = &amp;quot;# Scaffold&amp;quot;,&lt;br /&gt;
        ylab = &amp;quot;Length&amp;quot;,&lt;br /&gt;
        main = &amp;quot;Scaffold Lengths&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;View the plots:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing the PDF files:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the PDF files directly from the&lt;br /&gt;
left-hand file panel.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the PDF files to your&lt;br /&gt;
local computer and open them with any PDF viewer. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/best.coverage.pdf .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/scaffold.lengths.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The left plot shows length-weighted coverage: long contigs contribute more to the histogram. The right plot shows the raw distribution of contig coverage. Typically, most of the assembly will cluster around the expected coverage (e.g. ~60–90×), and shorter contigs will have more variable coverage. The scaffold length plot shows that most of the assembled bases are in relatively long scaffolds.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7. Why might some short contigs have much &amp;lt;i&amp;gt;higher&amp;lt;/i&amp;gt; coverage than the main assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8. Why might some short contigs have much &amp;lt;i&amp;gt;lower&amp;lt;/i&amp;gt; coverage than the main assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Assembly evaluation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use &amp;lt;b&amp;gt;QUAST&amp;lt;/b&amp;gt; to evaluate the assembly using various reference-based metrics.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;QUAST: [https://quast.sourceforge.net/quast quast]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run QUAST against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
  default_final.contigs.fa.gz \&lt;br /&gt;
  --threads 1 \&lt;br /&gt;
  -R /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/quast_results/latest/report.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9. The report lists several misassemblies. Can we always fully trust these “misassembly” calls? Why or why not?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Visualization using Circoletto&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will visualize the assembly against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference using Circoletto.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, filter out contigs shorter than 500 bp:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_filterfasta.sh default_final.contigs.fa.gz 500 &amp;gt; default_final.contigs_filtered_500.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;On your local machine, open a browser and go to:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://bat.infspire.org/circoletto/ Circoletto]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the filtered assembly in a text editor on the server, for example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit default_final.contigs_filtered_500.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste the FASTA content into the &amp;lt;b&amp;gt;“Query fasta”&amp;lt;/b&amp;gt; box on the Circoletto page.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then open the reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste this into the &amp;lt;b&amp;gt;“Subject fasta”&amp;lt;/b&amp;gt; box.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In the “Output” section, select &amp;lt;b&amp;gt;“ONLY show the best hit per query”&amp;lt;/b&amp;gt;, then click &amp;lt;b&amp;gt;Submit to Circoletto&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If Circoletto does not work, you can use this precomputed image:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/denovo/circoletto_results/cl0011524231.blasted.png&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You should see the two &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; chromosomes on the left (labelled with “gi|…”) and the alignment of your contigs to these chromosomes. Colours represent BLAST bitscores (red = high confidence, black = low).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10. Does your assembled genome appear broadly similar to the reference genome?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11. Are there contigs/scaffolds that do not map, or only partially map, to the reference?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12. On chromosome 2 (the smaller chromosome), there may be a region with many short, low-confidence hits. What might this region represent? Hint: see the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome paper and search for “V. cholerae integron island”: [https://www.nature.com/articles/35020000 V. cholerae genome paper]&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Try to assemble the genome using SPAdes (bonus)&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Different assemblers can perform very differently. &amp;lt;b&amp;gt;SPAdes&amp;lt;/b&amp;gt; is widely used and generally performs well. It performs error correction and uses multiple k-mer sizes internally.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;SPAdes: [https://ablab.github.io/spades/ SPAdes]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Check the help output:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/SPAdes-4.2.0-Linux/bin/spades.py -h&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; A full SPAdes run may take ~45 minutes. You can use the precomputed SPAdes assembly instead and compare to MEGAHIT using QUAST and Assemblathon stats.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Link to the SPAdes assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/denovo/vchol/spades/spades.fasta spades.fasta&lt;br /&gt;
# from here you can compute stats and run QUAST&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Annotation of a prokaryotic genome&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will annotate genes in &amp;lt;code&amp;gt;ecoli_pacbio.contigs.fasta&amp;lt;/code&amp;gt; using &amp;lt;b&amp;gt;prodigal&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Prodigal: [https://bmcbioinformatics.biomedcentral.com/articles/10.1186/1471-2105-11-119 prodigal]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output will be a GFF file with gene coordinates and a FASTA file with predicted proteins:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
prodigal \&lt;br /&gt;
  -f gff \&lt;br /&gt;
  -i [input genome in fasta] \&lt;br /&gt;
  -a [output proteins in fasta] \&lt;br /&gt;
  -o [output annotations in gff]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;GFF format: [https://www.ensembl.org/info/website/upload/gff.html GFF format description]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, index the protein FASTA file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract the protein sequence for gene ID &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa tig00000001_4582&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use BLASTP against the nr database:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://blast.ncbi.nlm.nih.gov/Blast.cgi?PROGRAM=blastp&amp;amp;PAGE_TYPE=BlastSearch&amp;amp;LINK_LOC=blasthome BLAST for proteins]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Paste the sequence and run BLASTP.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14. Which protein (function) does &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt; correspond to?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please find answers here: [[Denovo_solution|Denovo_solution]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=361</id>
		<title>Denovo exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Denovo_exercise&amp;diff=361"/>
		<updated>2026-01-06T13:41:40Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;h2&amp;gt;Overview&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to your home directory.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Create a directory called &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt;.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Navigate to the directory you just created.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In this exercise we will perform a &amp;lt;b&amp;gt;de novo assembly&amp;lt;/b&amp;gt; of Illumina paired-end reads. The data is from a &amp;lt;i&amp;gt;Vibrio cholerae&amp;lt;/i&amp;gt; strain isolated in Nepal. You will:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run FastQC and perform adapter/quality trimming (optional recap of pre-processing).&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Count k-mers and estimate genome size.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Correct reads using Musket.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Determine insert size of paired-end reads.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Run de novo assembly using MEGAHIT.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Calculate assembly statistics.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Plot coverage and length histograms of the assembly.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Evaluate the assembly quality.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Visualize the assembly using Circoletto.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;(Bonus) Try assembling the genome with SPAdes.&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Annotation of a prokaryotic genome.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;FastQC and trimming&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Make sure you are in the &amp;lt;code&amp;gt;denovo&amp;lt;/code&amp;gt; directory you created. You can double-check with:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pwd&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the sequencing data:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/* .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run FastQC on the reads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing FastQC HTML reports:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the FastQC HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_1_sequence_fastqc.html .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_2_sequence_fastqc.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;There are several issues with this dataset (you do not need to study the report in detail now). We will clean it up first. Let’s identify the quality encoding:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_detect_fq.sh Vchol-001_6_1_sequence.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1. Which quality encoding format is used?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Trim the reads using AdapterRemoval. The most frequent adapter/primer sequences are already included below. We use a minimum read length of 40 nt, trim to quality 20, and specify quality base 64. The &amp;lt;code&amp;gt;--basename&amp;lt;/code&amp;gt; option defines the output prefix and &amp;lt;code&amp;gt;--gzip&amp;lt;/code&amp;gt; compresses the output.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/adapterremoval-2.3.4/build/AdapterRemoval \&lt;br /&gt;
  --file1 Vchol-001_6_1_sequence.txt.gz \&lt;br /&gt;
  --file2 Vchol-001_6_2_sequence.txt.gz \&lt;br /&gt;
  --adapter1 GATCGGAAGAGCACACGTCTGAACTCCAGTCACATCACGATATCGTATGC \&lt;br /&gt;
  --adapter2 GATCGGAAGAGCGTCGTGTAGGGAAAGAGGGTAGATCTCGGTGGTCGCCG \&lt;br /&gt;
  --qualitybase 64 \&lt;br /&gt;
  --basename Vchol-001_6 \&lt;br /&gt;
  --gzip \&lt;br /&gt;
  --trimqualities \&lt;br /&gt;
  --minquality 20 \&lt;br /&gt;
  --minlength 40&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When it finishes, inspect &amp;lt;code&amp;gt;Vchol-001_6.settings&amp;lt;/code&amp;gt; for trimming statistics (how many reads were trimmed, discarded, etc.).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q1A. The output includes &amp;lt;code&amp;gt;discarded.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair1.truncated.gz&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;pair2.truncated.gz&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;singleton.truncated.gz&amp;lt;/code&amp;gt;. What types of reads does each file contain? (Tip: check the AdapterRemoval documentation.)&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, compute basic read stats (average read length, min/max length, number of reads, total bases) for the trimmed paired reads. Note down the average read length and total number of bases:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair1.truncated.gz&lt;br /&gt;
/home/ctools/bin/fastx_readlength.sh Vchol-001_6.pair2.truncated.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Genome size estimation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will count k-mers in the data. A k-mer is simply a DNA word of length k. We use &amp;lt;b&amp;gt;jellyfish&amp;lt;/b&amp;gt; to count 15-mers. We combine counts from forward and reverse-complement strands and then create a histogram. (This may take some time to run so could be good time to practice using &amp;quot;screen&amp;quot;)&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Manual: [http://www.cbcb.umd.edu/software/jellyfish/jellyfish-manual.html jellyfish]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip -dc Vchol-001_6.pair*.truncated.gz \&lt;br /&gt;
  | /home/ctools/jellyfish-2.3.1/bin/jellyfish count -t 2 -m 15 -s 1000000000 -o Vchol-001 -C /dev/fd/0&lt;br /&gt;
&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish histo Vchol-001 &amp;gt; Vchol-001.histo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;Vchol-001.histo&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
pdf(&amp;quot;Vchol-001.histo.pdf&amp;quot;)&lt;br /&gt;
barplot(dat[,2],&lt;br /&gt;
        xlim = c(0,150),&lt;br /&gt;
        ylim = c(0,5e5),&lt;br /&gt;
        ylab = &amp;quot;No of kmers&amp;quot;,&lt;br /&gt;
        xlab = &amp;quot;Counts of a k-mer&amp;quot;,&lt;br /&gt;
        names.arg = dat[,1],&lt;br /&gt;
        cex.names = 0.8)&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the pdf files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_1_sequence_fastqc.html .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/fastqc/Vchol-001_6_2_sequence_fastqc.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The plot shows:&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;x-axis: how many times a k-mer occurs (its count)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;y-axis: number of distinct k-mers with that count&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;K-mers that occur only a few times are typically due to sequencing errors. K-mers forming the main peak (higher counts) are likely “real” and can be used for error correction and genome size estimation.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q2. Where is the k-mer coverage peak (approximately)?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We can estimate genome size using:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
N = (M * L) / (L - K + 1)&lt;br /&gt;
Genome_size = T / N&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;N&amp;lt;/b&amp;gt; = depth (coverage)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;M&amp;lt;/b&amp;gt; = k-mer peak (from the histogram)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;K&amp;lt;/b&amp;gt; = k-mer size (here: 15)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;L&amp;lt;/b&amp;gt; = average read length (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&amp;lt;b&amp;gt;T&amp;lt;/b&amp;gt; = total number of bases (from fastx_readlength)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute the estimated genome size and compare with the known &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome (~4 Mb). You should be within roughly ±10%.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q3. What is your estimated genome size?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Error correction&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will correct errors in the reads using &amp;lt;b&amp;gt;Musket&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Musket: [http://musket.sourceforge.net/homepage.htm Musket]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, get the number of distinct k-mers (needed for memory allocation in Musket):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/jellyfish-2.3.1/bin/jellyfish stats Vchol-001&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use the reported number of distinct k-mers (here an example: &amp;lt;code&amp;gt;8423098&amp;lt;/code&amp;gt;) in the Musket command:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/musket-1.1/musket -k 15 8423098 -p 1 -omulti Vchol-001_6.cor -inorder \&lt;br /&gt;
  Vchol-001_6.pair1.truncated.gz Vchol-001_6.pair2.truncated.gz -zlib 1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output files are named &amp;lt;code&amp;gt;Vchol-001_6.cor.0&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;Vchol-001_6.cor.1&amp;lt;/code&amp;gt;. Rename them:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mv Vchol-001_6.cor.0 Vchol-001_6.pair1.cor.truncated.fq.gz&lt;br /&gt;
mv Vchol-001_6.cor.1 Vchol-001_6.pair2.cor.truncated.fq.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;If this takes too long, you can copy precomputed corrected reads:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/vchol/corrected/Vchol-001_6.pair*.cor.truncated.fq.gz .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;&amp;lt;i&amp;gt;De novo&amp;lt;/i&amp;gt; assembly with MEGAHIT&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now assemble the corrected reads using &amp;lt;b&amp;gt;MEGAHIT&amp;lt;/b&amp;gt; (a de Bruijn graph assembler). K-mer size is critical: MEGAHIT can test multiple k-mers by default, but here we start with a fixed k-mer size of 35.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, set the number of threads:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run MEGAHIT with k=35:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list 35 \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o 35&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;When finished, you should have &amp;lt;code&amp;gt;35/final.contigs.fa&amp;lt;/code&amp;gt;. Compress it:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gzip 35/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;To estimate insert size, we will map a subset of reads back to the assembly (similar to the alignment exercise). We’ll subsample the first 100,000 read pairs (400,000 lines per FASTQ):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat Vchol-001_6.pair1.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_1.fastq&lt;br /&gt;
zcat Vchol-001_6.pair2.cor.truncated.fq.gz | head -n 400000 &amp;gt; Vchol_sample_2.fastq&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Index the assembly and map:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
bwa index 35/final.contigs.fa.gz&lt;br /&gt;
&lt;br /&gt;
bwa mem 35/final.contigs.fa.gz Vchol_sample_1.fastq Vchol_sample_2.fastq \&lt;br /&gt;
  | samtools view -Sb - &amp;gt; Vchol_35bp.bam&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract insert sizes (TLEN field, column 9):&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools view Vchol_35bp.bam | cut -f9 &amp;gt; initial.insertsizes.txt&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
a   = read.table(&amp;quot;initial.insertsizes.txt&amp;quot;)&lt;br /&gt;
a.v = a[a[,1] &amp;gt; 0, 1]&lt;br /&gt;
mn  = quantile(a.v, seq(0,1,0.05))[4]&lt;br /&gt;
mx  = quantile(a.v, seq(0,1,0.05))[18]&lt;br /&gt;
mean(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])   # mean insert size&lt;br /&gt;
sd(a.v[a.v &amp;gt;= mn &amp;amp; a.v &amp;lt;= mx])     # standard deviation&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q4. What are the mean insert size and standard deviation of the library?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, we will explore different k-mer sizes. Each student chooses a different k-mer from this Google sheet:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://docs.google.com/spreadsheets/d/1trUMlSwNLoNW67D-OkgA93iOQRp2iioyJSBYyW30P4U/edit?usp=sharing Google sheet for k-mer assignment]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Write your name next to the k-mer you select, then run MEGAHIT with that k-mer, replacing &amp;lt;code&amp;gt;[KMER]&amp;lt;/code&amp;gt; below:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
export OMP_NUM_THREADS=4&lt;br /&gt;
/home/ctools/MEGAHIT-1.2.9-Linux-x86_64-static/bin/megahit \&lt;br /&gt;
  -1 Vchol-001_6.pair1.cor.truncated.fq.gz \&lt;br /&gt;
  -2 Vchol-001_6.pair2.cor.truncated.fq.gz \&lt;br /&gt;
  --k-list [KMER] \&lt;br /&gt;
  -t 4 \&lt;br /&gt;
  -m 2000000000 \&lt;br /&gt;
  -o [KMER]&lt;br /&gt;
&lt;br /&gt;
gzip [KMER]/final.contigs.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Compute assembly statistics using &amp;lt;code&amp;gt;QUAST&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
 [KMER]/final.contigs.fa.gz \&lt;br /&gt;
 --threads 1 \&lt;br /&gt;
 -o [KMER]/quast&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the file &amp;lt;code&amp;gt;[KMER]/quast/report.txt&amp;lt;/code&amp;gt; (or &amp;lt;code&amp;gt;report.tsv&amp;lt;/code&amp;gt;) and&lt;br /&gt;
record the following values in the Google sheet for your k-mer:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Number of contigs (&amp;amp;ge; 500 bp)&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Total assembly length&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;Largest contig&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;N50&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;As a class, compare results across k-mer sizes and discuss which k-mer produces&lt;br /&gt;
the most reasonable assembly and why.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy the best assembly to your folder, or use a precomputed multi-k assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.fa.gz .&lt;br /&gt;
cp /home/projects/22126_NGS/exercises/denovo/best/default_final.contigs.stats .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q5. How does the N50 of the best assembly (multi-k or default) compare to the N50 from the fixed-k assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q6. How does the longest contig length compare between fixed-k and multi-k/default assemblies?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Coverage of the assembly&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will now calculate per-contig coverage and lengths, and visualize them in R.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat default_final.contigs.fa.gz | /home/ctools/bin/fastx_megahit.sh --i /dev/stdin &amp;gt; default_finalt.cov&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Start R:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then paste:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
library(plotrix)&lt;br /&gt;
dat &amp;lt;- read.table(&amp;quot;default_finalt.cov&amp;quot;, sep = &amp;quot;\t&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
## ---- Coverage plots (2 panels) ----&lt;br /&gt;
pdf(&amp;quot;best.coverage.pdf&amp;quot;, width = 10, height = 5)&lt;br /&gt;
par(mfrow = c(1, 2))&lt;br /&gt;
&lt;br /&gt;
weighted.hist(w = dat[,2],&lt;br /&gt;
              x = dat[,1],&lt;br /&gt;
              breaks = seq(0, 100, 1),&lt;br /&gt;
              main = &amp;quot;Weighted coverage&amp;quot;,&lt;br /&gt;
              xlab = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
hist(dat[,1],&lt;br /&gt;
     xlim   = c(0, 100),&lt;br /&gt;
     breaks = seq(0, 1000, 1),&lt;br /&gt;
     main   = &amp;quot;Raw coverage&amp;quot;,&lt;br /&gt;
     xlab   = &amp;quot;Contig coverage&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&lt;br /&gt;
## ---- Scaffold lengths (1 panel) ----&lt;br /&gt;
pdf(&amp;quot;scaffold.lengths.pdf&amp;quot;, width = 7, height = 5)&lt;br /&gt;
par(mfrow = c(1, 1))&lt;br /&gt;
&lt;br /&gt;
barplot(rev(sort(dat[,2])),&lt;br /&gt;
        xlab = &amp;quot;# Scaffold&amp;quot;,&lt;br /&gt;
        ylab = &amp;quot;Length&amp;quot;,&lt;br /&gt;
        main = &amp;quot;Scaffold Lengths&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
dev.off()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;View the plots:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Viewing the PDF files:&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the PDF files directly from the&lt;br /&gt;
left-hand file panel.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the PDF files to your&lt;br /&gt;
local computer and open them with any PDF viewer. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/best.coverage.pdf .&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:path/to/scaffold.lengths.pdf .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The left plot shows length-weighted coverage: long contigs contribute more to the histogram. The right plot shows the raw distribution of contig coverage. Typically, most of the assembly will cluster around the expected coverage (e.g. ~60–90×), and shorter contigs will have more variable coverage. The scaffold length plot shows that most of the assembled bases are in relatively long scaffolds.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q7. Why might some short contigs have much &amp;lt;i&amp;gt;higher&amp;lt;/i&amp;gt; coverage than the main assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q8. Why might some short contigs have much &amp;lt;i&amp;gt;lower&amp;lt;/i&amp;gt; coverage than the main assembly?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Assembly evaluation&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will use &amp;lt;b&amp;gt;QUAST&amp;lt;/b&amp;gt; to evaluate the assembly using various reference-based metrics.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;QUAST: [https://quast.sourceforge.net/quast quast]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Run QUAST against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/quast/quast.py \&lt;br /&gt;
  default_final.contigs.fa.gz \&lt;br /&gt;
  --threads 1 \&lt;br /&gt;
  -R /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir fastqc&lt;br /&gt;
/home/ctools/FastQC/fastqc -o fastqc *.txt.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;MobaXterm&amp;lt;/b&amp;gt;, you can open the HTML files directly&lt;br /&gt;
from the left-hand file panel on the server.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If you are using &amp;lt;b&amp;gt;macOS&amp;lt;/b&amp;gt; (or a standard terminal), copy the HTML files to&lt;br /&gt;
your local computer and open them in a web browser. For example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp stud0XX@pupilX.healthtech.dtu.dk:denovo/quast_results/latest/report.html .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Replace &amp;lt;code&amp;gt;stud0XX&amp;lt;/code&amp;gt; with your student ID and &amp;lt;code&amp;gt;pupilX&amp;lt;/code&amp;gt; with the&lt;br /&gt;
compute node you are working on. The files will be copied to your current local&lt;br /&gt;
directory.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q9. The report lists several misassemblies. Can we always fully trust these “misassembly” calls? Why or why not?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Visualization using Circoletto&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will visualize the assembly against the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; reference using Circoletto.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;First, filter out contigs shorter than 500 bp:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/bin/fastx_filterfasta.sh default_final.contigs.fa.gz 500 &amp;gt; default_final.contigs_filtered_500.fa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;On your local machine, open a browser and go to:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://bat.infspire.org/circoletto/ Circoletto]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Open the filtered assembly in a text editor on the server, for example:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit default_final.contigs_filtered_500.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste the FASTA content into the &amp;lt;b&amp;gt;“Query fasta”&amp;lt;/b&amp;gt; box on the Circoletto page.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Then open the reference genome:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gedit /home/projects/22126_NGS/exercises/denovo/reference/vibrio_cholerae_O1_N16961.fa &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Copy–paste this into the &amp;lt;b&amp;gt;“Subject fasta”&amp;lt;/b&amp;gt; box.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;In the “Output” section, select &amp;lt;b&amp;gt;“ONLY show the best hit per query”&amp;lt;/b&amp;gt;, then click &amp;lt;b&amp;gt;Submit to Circoletto&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;If Circoletto does not work, you can use this precomputed image:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/projects/22126_NGS/exercises/denovo/circoletto_results/cl0011524231.blasted.png&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;You should see the two &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; chromosomes on the left (labelled with “gi|…”) and the alignment of your contigs to these chromosomes. Colours represent BLAST bitscores (red = high confidence, black = low).&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q10. Does your assembled genome appear broadly similar to the reference genome?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q11. Are there contigs/scaffolds that do not map, or only partially map, to the reference?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q12. On chromosome 2 (the smaller chromosome), there may be a region with many short, low-confidence hits. What might this region represent? Hint: see the &amp;lt;i&amp;gt;V. cholerae&amp;lt;/i&amp;gt; genome paper and search for “V. cholerae integron island”: [https://www.nature.com/articles/35020000 V. cholerae genome paper]&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Try to assemble the genome using SPAdes (bonus)&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Different assemblers can perform very differently. &amp;lt;b&amp;gt;SPAdes&amp;lt;/b&amp;gt; is widely used and generally performs well. It performs error correction and uses multiple k-mer sizes internally.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;SPAdes: [https://ablab.github.io/spades/ SPAdes]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Check the help output:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python3 /home/ctools/SPAdes-4.2.0-Linux/bin/spades.py -h&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; A full SPAdes run may take ~45 minutes. You can use the precomputed SPAdes assembly instead and compare to MEGAHIT using QUAST and Assemblathon stats.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Link to the SPAdes assembly:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/denovo/vchol/spades/spades.fasta spades.fasta&lt;br /&gt;
# from here you can compute stats and run QUAST&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt;Annotation of a prokaryotic genome&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;We will annotate genes in &amp;lt;code&amp;gt;ecoli_pacbio.contigs.fasta&amp;lt;/code&amp;gt; using &amp;lt;b&amp;gt;prodigal&amp;lt;/b&amp;gt;.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Prodigal: [https://bmcbioinformatics.biomedcentral.com/articles/10.1186/1471-2105-11-119 prodigal]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;The output will be a GFF file with gene coordinates and a FASTA file with predicted proteins:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
prodigal \&lt;br /&gt;
  -f gff \&lt;br /&gt;
  -i [input genome in fasta] \&lt;br /&gt;
  -a [output proteins in fasta] \&lt;br /&gt;
  -o [output annotations in gff]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;GFF format: [https://www.ensembl.org/info/website/upload/gff.html GFF format description]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Next, index the protein FASTA file:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Extract the protein sequence for gene ID &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt;:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools faidx ecoli_pacbio.contigs.aa tig00000001_4582&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Use BLASTP against the nr database:&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;[https://blast.ncbi.nlm.nih.gov/Blast.cgi?PROGRAM=blastp&amp;amp;PAGE_TYPE=BlastSearch&amp;amp;LINK_LOC=blasthome BLAST for proteins]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Paste the sequence and run BLASTP.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Q14. Which protein (function) does &amp;lt;code&amp;gt;tig00000001_4582&amp;lt;/code&amp;gt; correspond to?&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;Please find answers here: [[Denovo_solution|Denovo_solution]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;b&amp;gt;Congratulations, you finished the exercise!&amp;lt;/b&amp;gt;&amp;lt;/p&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
	<entry>
		<id>https://teaching.healthtech.dtu.dk/22126/index.php?title=Ancient_DNA_exercise&amp;diff=360</id>
		<title>Ancient DNA exercise</title>
		<link rel="alternate" type="text/html" href="https://teaching.healthtech.dtu.dk/22126/index.php?title=Ancient_DNA_exercise&amp;diff=360"/>
		<updated>2026-01-06T13:38:57Z</updated>

		<summary type="html">&lt;p&gt;Mick: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;H2&amp;gt;Overview&amp;lt;/H2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adapted from Martin Sikora.&lt;br /&gt;
&lt;br /&gt;
First:&lt;br /&gt;
&amp;lt;OL&amp;gt;&lt;br /&gt;
&amp;lt;LI&amp;gt;Navigate to your home directory:&lt;br /&gt;
&amp;lt;LI&amp;gt;Create a directory called &amp;quot;adna&amp;quot; &lt;br /&gt;
&amp;lt;LI&amp;gt;Navigate to the directory you just created.&lt;br /&gt;
&amp;lt;/OL&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We will try to &lt;br /&gt;
# Authenticate ancient DNA&lt;br /&gt;
# do some basic population genetics&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Data authentication&amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Authentication involves making sure that the DNA that you have extracted from my fossil and sequenced is indeed from the fossil and not some modern contaminant. A big difference between modern DNA and ancient DNA is the presence of chemical damage due to the passage of time. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt; Direct measurements of the rate of chemical damage&amp;lt;/h3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, create a directory:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir  01_authentication&lt;br /&gt;
cd 01_authentication&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We will characterize DNA damage patterns using mapDamage, a software to estimate the rate of nucleotide substitution. In this section, we will examine some example BAM files for the presence of DNA damage patterns typical of ancient DNA.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have a set of 10 modern and 26 ancient individuals (subsampled to 100k reads)&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
find /home/projects/22126_NGS/exercises/adna/01_authentication/bam/ -name &amp;quot;*bam&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, run mapDamage on one of the modern individuals:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mapDamage -i /home/projects/22126_NGS/exercises/adna/01_authentication/bam/modern/NA20786.mapped.ILLUMINA.bwa.TSI.low_coverage.20130415.100k_ss.bam -r /home/databases/references/human/hs37d5.fa --no-stats&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output &amp;lt;b&amp;gt;(either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd NA20786.mapped.ILLUMINA.bwa.TSI.low_coverage.20130415.100k_ss.mapDamage/&lt;br /&gt;
Length_plot.pdf&lt;br /&gt;
Fragmisincorporation_plot.pdf&lt;br /&gt;
cd ..&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q1:&#039;&#039;&#039; which fragment length occurs most frequently?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q2:&#039;&#039;&#039; what is the frequency of 5&#039; C&amp;gt;T and 3&#039; G&amp;gt;A substitutions ()&lt;br /&gt;
&lt;br /&gt;
Run mapDamage on one of the ancient individuals&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mapDamage -i  /home/projects/22126_NGS/exercises/adna/01_authentication/bam/ancient/allentoft_2015/RISE559.sort.rmdup.realign.md.100k.bam -r /home/databases/references/human/hs37d5.fa --no-stats&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output &amp;lt;b&amp;gt;(either via mobaxterm or by downloading it locally)&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd RISE559.sort.rmdup.realign.md.100k.mapDamage/&lt;br /&gt;
Length_plot.pdf &amp;amp;&lt;br /&gt;
Fragmisincorporation_plot.pdf &amp;amp;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q3:&#039;&#039;&#039; At what fragment length does the distribution show its peak?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q4:&#039;&#039;&#039; what are the frequencies of 5&#039; C&amp;gt;T (red line) and 3&#039; G&amp;gt;A substitutions (blue line)?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q5:&#039;&#039;&#039; which bases are enriched at 5&#039; flanking position?&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q6:&#039;&#039;&#039; does your sample look ancient? if not, what might be the reason?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H2&amp;gt; Population genetics &amp;lt;/H2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a new subdirectory and navigate to it:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd ..&lt;br /&gt;
mkdir 02_popgen&lt;br /&gt;
cd 02_popgen&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Explore the reference panel dataset&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Pur reference panel dataset is in binary PLINK format, a widely used format in genetic studies (see documentation [https://www.cog-genomics.org/plink/1.9/ here]). We need to access the following files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ls /home/projects/22126_NGS/exercises/adna/02_popgen/plink/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
However, instead of copying them, we will create symbolic links using the ln command, these acts as placeholders and tell the operating system to pretend that there is an actual file there. This saves considerable disk space compared to copying over the files. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.bed .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.bim .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.cluster .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.fam .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/plink/world.sampleInfo.txt .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/eur.poplist .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/modern.poplist .&lt;br /&gt;
ln -s /home/projects/22126_NGS/exercises/adna/02_popgen/noneur.poplist .&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The PLINK binary format consists of 3 files:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;file&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;description&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
| world.bed&lt;br /&gt;
| | genotype data in binary format (&#039;&#039;&#039;not to be confused with genomic intervals bed file but it is confusing&#039;&#039;&#039;)&lt;br /&gt;
|-&lt;br /&gt;
| world.bim&lt;br /&gt;
| metadata for the variants, 1 line per variant&lt;br /&gt;
|-&lt;br /&gt;
| world.fam&lt;br /&gt;
| metadata for the samples, 1 line per sample&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We also have the following files than contain extra information:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;file&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;description&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
|world.cluster&lt;br /&gt;
| pre-defined population groupings for samples (for plink)&lt;br /&gt;
|-&lt;br /&gt;
| world.sampleInfo.txt&lt;br /&gt;
| additional sample metadata (for plotting etc)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Let us explore the metadata files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
head world.fam&lt;br /&gt;
head world.bim&lt;br /&gt;
head world.cluster&lt;br /&gt;
head world.sampleInfo.txt&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q7:&#039;&#039;&#039; How many samples / SNPs are in our dataset?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q8:&#039;&#039;&#039; what populations are in our reference panel and what sample size do they have (trick: forgo the header using &amp;quot;tail -n+2&amp;quot;, you need &amp;quot;sort&amp;quot; and uniq (prints 1 instance per repeated line), to tell &amp;quot;uniq&amp;quot; to count and print how many lines were repeated &amp;quot;-c&amp;quot;?&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Calculate basic summary statistics (a simple description of the data) for the dataset:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile world --missing --out world&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q9:&#039;&#039;&#039;  are you getting the same number of variants and individuals as you did via UNIX command lines?&lt;br /&gt;
&lt;br /&gt;
The world.imiss file lists the number and fraction of missing genotypes for each sample&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q10:&#039;&#039;&#039; what fraction of SNPs have a missing genotype for the Tyrolean Iceman?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Genotype and merge an ancient individual&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this section, we will merge our ancient data with the reference panel to prepare our dataset for downstream analysis genotypes for our ancient data will be obtained by randomly sampling a read from the alignments (BAM files) at the reference dataset SNP positions.&lt;br /&gt;
&lt;br /&gt;
We are going to use a low-coverage individual from [https://pubmed.ncbi.nlm.nih.gov/26062507/ Allentoft et al (RISE507)], this data was obtained from an ~5100-year-old individual from the Early Bronze Age [https://en.wikipedia.org/wiki/Afanasievo_culture Afanasievo culture] in the Altai Mountains region&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ls /home/projects/22126_NGS/exercises/adna/02_popgen/bam/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First, we need to extract a genomic interval bed file for the SNP positions of the reference panel:&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
awk &#039;{print $1&amp;quot;\t&amp;quot;($4-1)&amp;quot;\t&amp;quot;$4}&#039; world.bim | gzip &amp;gt; world.snps.bed.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
awk is a command to create small programs. In this example, we tell it, print the first columns, the fourth column minus 1 and the fourth column again.&lt;br /&gt;
 &lt;br /&gt;
Inspect the results:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat world.snps.bed.gz | head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a read pileup file for the reference panel SNP positions (might take a few minutes) &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
samtools mpileup -f /home/databases/references/human/hs37d5.fa -B -l world.snps.bed.gz /home/projects/22126_NGS/exercises/adna/02_popgen/bam/RISE507.sort.rmdup.realign.md.bam |gzip &amp;gt; RISE507.pileup.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Examine the output:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.pileup.gz |head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q11&#039;&#039;&#039;: how many SNPs of the reference panel are covered in RISE507?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we will randomly sample a DNA fragment at each position and output the results in VCF format (custom python script):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.pileup.gz | /home/ctools/Python-2.7.18/bin/python2.7 /home/projects/22126_NGS/exercises/adna/02_popgen/get_haploid_vcf_from_pileup.py -r -s RISE507 |/home/ctools/htslib-1.20/bgzip -c &amp;gt; RISE507.vcf.gz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
This is done because the coverage is insufficient to ensure proper genotyping.&lt;br /&gt;
&lt;br /&gt;
Let us inspect the result:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
zcat RISE507.vcf.gz |grep -v &amp;quot;^#&amp;quot; |head&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We convert to plink binary format:&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
/home/ctools/plink --vcf RISE507.vcf.gz --make-bed --double-id --out RISE507&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Try to merge the sample with the reference panel&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
/home/ctools/plink --bfile world --bmerge RISE507 --out RISE507.merge&lt;br /&gt;
&amp;lt;/pre&amp;gt; &lt;br /&gt;
&lt;br /&gt;
You should get an error.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q12&#039;&#039;&#039;: how many SNPs failed the merge? What is the likely reason?&lt;br /&gt;
&lt;br /&gt;
We will remove the failing SNPs and try again&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507 --exclude RISE507.merge.missnp --make-bed --out RISE507.merge2&lt;br /&gt;
/home/ctools/plink --bfile world --bmerge RISE507.merge2 --out RISE507.world&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Make a cluster file for subsetting&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
awk &#039;{print $1,$2,$1}&#039; RISE507.world.fam &amp;gt; RISE507.world.cluster&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;H3&amp;gt;Investigate the genetic affinities of the ancient sample using PCA&amp;lt;/H3&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this section, we will try to place our sample within a PCA of a set of modern and ancient individuals.&lt;br /&gt;
&lt;br /&gt;
First, we will have a look at the modern populations in the reference panel:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --keep-clusters modern.poplist --within RISE507.world.cluster --pca header tabs --out modern&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We can plot the first two principal components using the custom R script plotPca.R&lt;br /&gt;
&lt;br /&gt;
The three positional arguments are the eigenvector file, sample info file and prefix for the output &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R modern.eigenvec world.sampleInfo.txt modern&lt;br /&gt;
modern.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q13:&#039;&#039;&#039; which populations are most differentiated along PC1?&lt;br /&gt;
&#039;&#039;&#039;Q14:&#039;&#039;&#039; which populations are most differentiated along PC2?&lt;br /&gt;
&lt;br /&gt;
We repeat the exercise on a subset of European populations &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --keep-clusters eur.poplist --within RISE507.world.cluster --pca header tabs --out eur&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R eur.eigenvec world.sampleInfo.txt eur&lt;br /&gt;
eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q15:&#039;&#039;&#039; which populations are most differentiated along PC1?&lt;br /&gt;
&#039;&#039;&#039;Q16:&#039;&#039;&#039; which populations are most differentiated along PC2?&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Now, let us examine how the cluster of ancient individuals compared to the modern ones &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --pca header tabs --out ancient.world&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient.world.eigenvec world.sampleInfo.txt ancient.world&lt;br /&gt;
ancient.world.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here are some references if you want to read more about the different ancient samples:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| &#039;&#039;&#039;sample&#039;&#039;&#039;&lt;br /&gt;
| &#039;&#039;&#039;link&#039;&#039;&#039;    &lt;br /&gt;
|-&lt;br /&gt;
| UstIshim&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Ust%27-Ishim_man]&lt;br /&gt;
|-&lt;br /&gt;
| Loschbour&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Loschbour_man] [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4170574/]&lt;br /&gt;
|-&lt;br /&gt;
| Brana&lt;br /&gt;
| [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4269527/]&lt;br /&gt;
|-&lt;br /&gt;
| NE1&lt;br /&gt;
| [https://www.pnas.org/content/113/2/368]&lt;br /&gt;
|-&lt;br /&gt;
|Stuttgart&lt;br /&gt;
| [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4170574/]&lt;br /&gt;
|-&lt;br /&gt;
| Iceman&lt;br /&gt;
| [https://www.iceman.it/en/the-iceman/]&lt;br /&gt;
|-&lt;br /&gt;
|Karelia&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Karelians]&lt;br /&gt;
|-&lt;br /&gt;
| Samara&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Samara_culture]&lt;br /&gt;
|-&lt;br /&gt;
| MA1&lt;br /&gt;
| [https://en.wikipedia.org/wiki/Mal%27ta%E2%80%93Buret%27_culture]&lt;br /&gt;
|-&lt;br /&gt;
| RISE507&lt;br /&gt;
|[https://pubmed.ncbi.nlm.nih.gov/26062507/]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q17:&#039;&#039;&#039; which ancient individuals don&#039;t cluster close to any modern individuals? what could be a plausible reason?&lt;br /&gt;
&lt;br /&gt;
Repeat the exercise but remove the non-European modern individuals &amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --within RISE507.world.cluster --remove-clusters noneur.poplist --pca header tabs --out ancient.eur&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient.eur.eigenvec world.sampleInfo.txt ancient.eur&lt;br /&gt;
ancient.eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q18:&#039;&#039;&#039; which populations are most differentiated along PC1? what could be a plausible reason?&lt;br /&gt;
&lt;br /&gt;
As a final exercise, we now project the ancient individual on PCs inferred from modern Europeans&amp;lt;b&amp;gt;(view the pdf either via mobaxterm or by downloading it locally):&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/home/ctools/plink --bfile RISE507.world --within RISE507.world.cluster --pca-clusters eur.poplist --remove-clusters noneur.poplist --pca header tabs --out ancient_proj.eur --maf 0.01&lt;br /&gt;
Rscript /home/projects/22126_NGS/exercises/adna/02_popgen/plotPca.R ancient_proj.eur.eigenvec world.sampleInfo.txt ancient_proj.eur&lt;br /&gt;
ancient_proj.eur.pca.plot.pdf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q19:&#039;&#039;&#039; where does our study individual cluster now?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Q20:&#039;&#039;&#039; How do you explain that an individual that is found closer to the modern-day Chinese border is closer to modern Europeans than he is to the Han Chinese?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Please find answers [[Ancient_DNA_exercise_answers|here]]&lt;/div&gt;</summary>
		<author><name>Mick</name></author>
	</entry>
</feed>