CSMSL.Examples.TrypticDigestion.ExampleDigestion C# (CSharp) Метод

ExampleDigestion() публичный статический Метод

public static ExampleDigestion ( ) : void
Результат void
        public static void ExampleDigestion()
        {
            const string fastaFilePath = "Resources/yeast_uniprot_120226.fasta";
            IProtease trypsin = Protease.GetProtease("Trypsin");
            const int maxMissedCleavages = 3;
            const int minPeptideLength = 5;
            const int maxPeptideLength = 50;
            List<double> masses = new List<double>();
            Stopwatch watch = new Stopwatch();
            watch.Start();
            using (FastaReader reader = new FastaReader(fastaFilePath))
            {
                foreach (Protein protein in reader.ReadNextProtein())
                {
                    foreach (Peptide peptide in protein.Digest(trypsin, maxMissedCleavages, minPeptideLength, maxPeptideLength))
                    {
                        masses.Add(peptide.MonoisotopicMass);
                    }
                }
            }
            //Console.WriteLine("Average Peptide Mass = {0:F4}", masses.Average());
            watch.Stop();
            Console.WriteLine("Time elapsed: {0}", watch.Elapsed);
        }