/// <summary>
 /// Outputs the data for a FastqFile to the console, keeping code clean in other classes
 /// </summary>
 /// <param name="fqFile"></param>
 public void OutputFileDataToConsole(IFqFile fqFile)
 {
     Console.WriteLine("Joint Test Results Completed on " + fqFile.getTotalNucleotides() + " Nucleotides");
     Console.WriteLine("Joint Test Results: " + fqFile.getGCount() + "G   " + Math.Round(fqFile.gContents(), 2) + "%   " + fqFile.getCCount() + "C " + Math.Round(fqFile.cContents(), 2) + " %");
     Console.WriteLine("Misreads:  " + fqFile.getNCount());
     Console.WriteLine("Nucleotides Cleaned: {0}", fqFile.getNucleotidesCleaned());
     Console.WriteLine("Distribution:  " + fqFile.getDistribution().Count);
     Console.WriteLine("Stats Performed");
     for (int i = 0; i < 20; i++)
     {
         FqSequence fqSeq = fqFile.getFastqSequenceByPosition(i);
         Console.WriteLine("--  -Stats for Sequence " + (i + 1) + ": LB: {0}  1Q: {1}  Median: {2} Mean: {3} 3Q: {4} UB: {5}", fqSeq.getLowerThreshold(), fqSeq.getFirstQuartile(), fqSeq.getMedian(), Math.Round(fqSeq.getMean(), 2), fqSeq.getThirdQuartile(), fqSeq.getUpperThreshold());
     }
     for (int i = 0; i < fqFile.getDistribution().Count; i++)
         Console.WriteLine("--->  Quality Score: {0}   Count: {1}", i, fqFile.getDistribution()[i]);
     for (int i = 0; i < fqFile.GetPerBaseStatisticsArray().Length; i ++)
         Console.WriteLine("===> BaseStatistic: {0} \tCount: {1} LB: {2}  1Q: {3}  Median: {4} Mean: {5} 3Q: {6} UB: {7}", i, fqFile.GetPerBaseStatisticsArray()[i].BaseCount, fqFile.GetPerBaseStatisticsArray()[i].LowerThreshold, fqFile.GetPerBaseStatisticsArray()[i].FirstQuartile, fqFile.GetPerBaseStatisticsArray()[i].Median, fqFile.GetPerBaseStatisticsArray()[i].Mean, fqFile.GetPerBaseStatisticsArray()[i].ThirdQuartile, fqFile.GetPerBaseStatisticsArray()[i].UpperThreshold);
 }
 /// <summary>
 /// Outputs the data for a FastqFile to the console, keeping code clean in other classes
 /// </summary>
 /// <param name="fqFile"></param>
 public void OutputFileDataToConsole(IFqFile fqFile)
 {
     Console.WriteLine("Joint Test Results Completed on " + fqFile.getTotalNucleotides() + " Nucleotides");
     Console.WriteLine("Joint Test Results: " + fqFile.getGCount() + "G   " + Math.Round(fqFile.gContents(), 2) + "%   " + fqFile.getCCount() + "C " + Math.Round(fqFile.cContents(), 2) + " %");
     Console.WriteLine("Misreads:  " + fqFile.getNCount());
     Console.WriteLine("Nucleotides Cleaned: {0}", fqFile.getNucleotidesCleaned());
     Console.WriteLine("Distribution:  " + fqFile.getDistribution().Count);
     Console.WriteLine("Stats Performed");
     for (int i = 0; i < 20; i++)
     {
         FqSequence fqSeq = fqFile.getFastqSequenceByPosition(i);
         Console.WriteLine("--  -Stats for Sequence " + (i + 1) + ": LB: {0}  1Q: {1}  Median: {2} Mean: {3} 3Q: {4} UB: {5}", fqSeq.getLowerThreshold(), fqSeq.getFirstQuartile(), fqSeq.getMedian(), Math.Round(fqSeq.getMean(), 2), fqSeq.getThirdQuartile(), fqSeq.getUpperThreshold());
     }
     for (int i = 0; i < fqFile.getDistribution().Count; i++)
     {
         Console.WriteLine("--->  Quality Score: {0}   Count: {1}", i, fqFile.getDistribution()[i]);
     }
     for (int i = 0; i < fqFile.GetPerBaseStatisticsArray().Length; i++)
     {
         Console.WriteLine("===> BaseStatistic: {0} \tCount: {1} LB: {2}  1Q: {3}  Median: {4} Mean: {5} 3Q: {6} UB: {7}", i, fqFile.GetPerBaseStatisticsArray()[i].BaseCount, fqFile.GetPerBaseStatisticsArray()[i].LowerThreshold, fqFile.GetPerBaseStatisticsArray()[i].FirstQuartile, fqFile.GetPerBaseStatisticsArray()[i].Median, fqFile.GetPerBaseStatisticsArray()[i].Mean, fqFile.GetPerBaseStatisticsArray()[i].ThirdQuartile, fqFile.GetPerBaseStatisticsArray()[i].UpperThreshold);
     }
 }
 public void ContructComponentDetails(IFqFile component)
 {
     this.ComponentName              = component.getFileName();
     this.FileName                   = component.getFileName();
     this.sequencerType              = component.getSequencerType();
     this.ComponentNumber            = component.getComponentNumber();
     this.TotalNucs                  = component.getTotalNucleotides();
     this.TotalSequences             = component.getFastqArraySize();
     this.NucleotidesCleaned         = component.getNucleotidesCleaned();
     this.Distribution               = component.getDistribution();
     this.SequenceLengthDistribution = component.getSequenceLengthDistribution();
     this.NCount            = component.getNCount();
     this.CCount            = component.getCCount();
     this.GCount            = component.getGCount();
     this.MaxSeqSize        = component.getMaxSeqSize();
     this.MinSeqSize        = component.getMinSeqSize();
     this.NPercent          = component.nContents();
     this.CPercent          = component.cContents();
     this.GPercent          = component.gContents();
     this.SequencesRemoved  = component.getSequencesRemoved();
     this.RemovedAdapters   = component.getRemovedAdapters();
     this.perBaseStatistics = component.GetPerBaseStatisticsArray();
 }
 public void ContructComponentDetails(IFqFile component)
 {
     this.ComponentName = component.getFileName();
     this.FileName = component.getFileName();
     this.sequencerType = component.getSequencerType();
     this.ComponentNumber = component.getComponentNumber();
     this.TotalNucs = component.getTotalNucleotides();
     this.TotalSequences = component.getFastqArraySize();
     this.NucleotidesCleaned = component.getNucleotidesCleaned();
     this.Distribution = component.getDistribution();
     this.SequenceLengthDistribution = component.getSequenceLengthDistribution();
     this.NCount = component.getNCount();
     this.CCount = component.getCCount();
     this.GCount = component.getGCount();
     this.MaxSeqSize = component.getMaxSeqSize();
     this.MinSeqSize = component.getMinSeqSize();
     this.NPercent = component.nContents();
     this.CPercent = component.cContents();
     this.GPercent = component.gContents();
     this.SequencesRemoved = component.getSequencesRemoved();
     this.RemovedAdapters = component.getRemovedAdapters();
     this.perBaseStatistics = component.GetPerBaseStatisticsArray();
 }