private void AddGeneralProcessor(CompositeProcessor <PeakList <Peak> > result)
        {
            result.Add(new PeakListMassRangeProcessor <Peak>(PrecursorMassRange.From, PrecursorMassRange.To, new int[] { 2, 3 }));

            result.Add(new PeakListMinIonIntensityProcessor <Peak>(MinimumIonIntensity));

            result.Add(new PeakListMinIonCountProcessor <Peak>(MinimumIonCount));

            result.Add(new PeakListMinTotalIonIntensityProcessor <Peak>(MinimumTotalIonIntensity));
        }
        public Raw2MgfProcessor GetRaw2MgfProcessor()
        {
            PeakListMassRangeProcessor <Peak>            p1 = new PeakListMassRangeProcessor <Peak>(MinimumMass, MaximumMass, new int[] { 2, 3 });
            PeakListMinIonIntensityProcessor <Peak>      p2 = new PeakListMinIonIntensityProcessor <Peak>(MinimumIonIntensity);
            PeakListMinIonCountProcessor <Peak>          p3 = new PeakListMinIonCountProcessor <Peak>(MinIonCount);
            PeakListMinTotalIonIntensityProcessor <Peak> p4 = new PeakListMinTotalIonIntensityProcessor <Peak>(MinimumTotalIonCount);

            CompositeProcessor <PeakList <Peak> > p = new CompositeProcessor <PeakList <Peak> >();

            p.Add(p1);
            p.Add(p2);
            p.Add(p3);
            p.Add(p4);

            return(new Raw2MgfProcessor(null, GetMascotGenericFormatWriter(), GetRetentionTime(), PrecursorTolerance, PeakTolerance, p, new DirectoryInfo(TargetDirectory), GroupByScanMode));
        }
        public CompositeProcessor <PeakList <Peak> > GetProcessor(string fileName, IProgressCallback callBack)
        {
            CompositeProcessor <PeakList <Peak> > result = new CompositeProcessor <PeakList <Peak> >();

            if (!this.OutputMzXmlFormat)
            {
                AddGeneralProcessor(result);
            }

            if (RemoveIons)
            {
                if (RemoveIsobaricIons)
                {
                    result.Add(GetIsobaricProcessor());
                }

                if (RemoveSpecialIons)
                {
                    var ranges = ParseRemoveMassRange();
                    foreach (var range in ranges)
                    {
                        result.Add(new PeakListRemoveMassRangeProcessor <Peak>(range.From, range.To));
                    }
                }
            }

            if (Deisotopic)
            {
                result.Add(new PeakListDeisotopicByChargeProcessor <Peak>(ProductIonPPM));
            }

            if (PrecursorOptions.RemovePrecursor)
            {
                result.Add(new PeakListRemovePrecursorProcessor <Peak>(this.PrecursorOptions));
            }

            if (ChargeDeconvolution)
            {
                result.Add(new PeakListDeconvolutionByChargeProcessor <Peak>(ProductIonPPM));
                if (Deisotopic)
                {
                    result.Add(new PeakListDeisotopicByChargeProcessor <Peak>(ProductIonPPM));
                }
            }

            if (KeepTopX)
            {
                result.Add(new PeakListTopXProcessor <Peak>(TopX));
            }

            return(result);
        }
Beispiel #4
0
 public SimpleProteinGroupBuilder(string[] perferReferenceRegexString)
 {
     processor = new CompositeProcessor <IIdentifiedProteinGroup>();
     processor.Add(new ProteinNameProcessor(perferReferenceRegexString));
     processor.Add(new ProteinLengthProcessor(false));
 }