diff --git a/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/gatk/BaseRecalibrator.scala b/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/gatk/BaseRecalibrator.scala
index 567a8af4e38686174708c32b89786f180060bcef..5551164ba956181e0a93ef08969ebe48ab4e0f7b 100644
--- a/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/gatk/BaseRecalibrator.scala
+++ b/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/gatk/BaseRecalibrator.scala
@@ -22,7 +22,7 @@ import nl.lumc.sasc.biopet.utils.config.Configurable
 import org.broadinstitute.gatk.queue.extensions.gatk.TaggedFile
 import org.broadinstitute.gatk.utils.commandline.{ Argument, Gather, Output, Input }
 
-class BaseRecalibrator(val root: Configurable) extends CommandLineGATK  with ScatterGatherableFunction {
+class BaseRecalibrator(val root: Configurable) extends CommandLineGATK with ScatterGatherableFunction {
   def analysis_type = "BaseRecalibrator"
   scatterClass = classOf[ContigScatterFunction]
   setupScatterFunction = { case scatter: GATKScatterFunction => scatter.includeUnmapped = false }
diff --git a/flexiprep/src/main/resources/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepReadSummary.ssp b/flexiprep/src/main/resources/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepReadSummary.ssp
index fc8b8ce55816d6b45b9937157ca6ae048e8f7a3c..a79af000e41eae8b9871b5dfc40ed2a08a508e66 100644
--- a/flexiprep/src/main/resources/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepReadSummary.ssp
+++ b/flexiprep/src/main/resources/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepReadSummary.ssp
@@ -19,6 +19,10 @@
     val trimCount = summary.getLibraryValues("flexiprep", "settings", "skip_trim").count(_._2 == Some(false))
     val clipCount = summary.getLibraryValues("flexiprep", "settings", "skip_clip").count(_._2 == Some(false))
     val librariesCount = summary.samples.foldLeft(0)(_ + summary.libraries(_).size)
+
+    val paired: Boolean = if (sampleId.isDefined && libId.isDefined)
+    summary.getLibraryValue(sampleId.get, libId.get, "flexiprep", "settings", "paired").get.asInstanceOf[Boolean]
+    else summary.getLibraryValues("flexiprep", "settings", "paired").values.exists(_ == Some(true))
 }#
 
 #if (showIntro)
@@ -62,9 +66,6 @@
 
 #if (showPlot)
     #{
-        val paired: Boolean = if (sampleId.isDefined && libId.isDefined)
-            summary.getLibraryValue(sampleId.get, libId.get, "flexiprep", "settings", "paired").get.asInstanceOf[Boolean]
-        else summary.getLibraryValues("flexiprep", "settings", "paired").values.exists(_ == Some(true))
         FlexiprepReport.readSummaryPlot(outputDir, "QC_Reads_R1","R1", summary, sampleId = sampleId)
         if (paired) FlexiprepReport.readSummaryPlot(outputDir, "QC_Reads_R2","R2", summary, sampleId = sampleId)
     }#
@@ -105,6 +106,7 @@
         <th>Before QC</th>
         <th>Clipping</th>
         <th>Trimming</th>
+        #if (paired == true) <th>Out of Sync</th> #end
         <th>After QC</th>
     </tr></thead>
     <tbody>
@@ -140,8 +142,8 @@
                     #for (read <- reads)
                         #if (read == "R2") </tr><tr> #end
                         #{
-                            val beforeTotal = summary.getLibraryValue(sample, libId, "flexiprep", "stats", "seqstat_" + read, "reads", "num_total")
-                            val afterTotal = summary.getLibraryValue(sample, libId, "flexiprep", "stats", "seqstat_" + read + "_qc", "reads", "num_total")
+                            val beforeTotal = summary.getLibraryValue(sample, libId, "flexiprep", "stats", "seqstat_" + read, "reads", "num_total").getOrElse(0).toString.toLong
+                            val afterTotal = summary.getLibraryValue(sample, libId, "flexiprep", "stats", "seqstat_" + read + "_qc", "reads", "num_total").getOrElse(0).toString.toLong
                             val clippingDiscardedToShort = summary.getLibraryValue(sample, libId, "flexiprep", "stats", "clipping_" + read, "num_reads_discarded_too_short").getOrElse(0).toString.toLong
                             val clippingDiscardedToLong = summary.getLibraryValue(sample, libId, "flexiprep", "stats", "clipping_" + read, "num_reads_discarded_too_long").getOrElse(0).toString.toLong
                             var trimmingDiscarded = summary.getLibraryValue(sample, libId, "flexiprep", "stats", "trimming_" + read, "num_reads_discarded_total").getOrElse(0).toString.toLong
@@ -150,6 +152,7 @@
                         <td>${beforeTotal}</td>
                         <td>${clippingDiscardedToShort + clippingDiscardedToLong}</td>
                         <td>${trimmingDiscarded}</td>
+                        #if (paired == true) <td>${beforeTotal - clippingDiscardedToShort - clippingDiscardedToLong - trimmingDiscarded - afterTotal}</td> #end
                         <td>${afterTotal}</td>
                     #end
                 </tr>