Пример #1
0
 public void TestRatioToStandard()
 {
     var doc = LoadTestDocument();
     foreach (var peptideGroup in doc.MoleculeGroups)
     {
         foreach (var peptide in peptideGroup.Peptides)
         {
             var peptideQuantifier = new PeptideQuantifier(peptideGroup, peptide,
                 QuantificationSettings.DEFAULT.ChangeNormalizationMethod(NormalizationMethod.GetNormalizationMethod(IsotopeLabelType.heavy)));
             for (int replicateIndex = 0; replicateIndex < doc.Settings.MeasuredResults.Chromatograms.Count; replicateIndex++)
             {
                 var expected = peptide.Results[replicateIndex].First().LabelRatios.First().Ratio.Ratio;
                 var actual = PeptideQuantifier.SumQuantities(
                     peptideQuantifier.GetTransitionIntensities(doc.Settings, replicateIndex).Values,
                     peptideQuantifier.NormalizationMethod).Value;
                 Assert.AreEqual(expected, actual, .0001, "Error on replicate {0}", replicateIndex);
             }
         }
     }
 }
 private CalibrationCurveFitter GetCalibrationCurveFitter(SrmDocument document)
 {
     var peptideQuantifier = new PeptideQuantifier(
         document.MoleculeGroups.First(),
         document.Peptides.First(), document.Settings.PeptideSettings.Quantification);
     return new CalibrationCurveFitter(peptideQuantifier, document.Settings);
 }
Пример #3
0
 public CalibrationCurveFitter(PeptideQuantifier peptideQuantifier, SrmSettings srmSettings)
 {
     PeptideQuantifier = peptideQuantifier;
     SrmSettings = srmSettings;
 }