Exemplo n.º 1
0
        private static Database databaseSetUp(String fasta_file_name)
        {
            FastaFile         f  = Loader.parseFasta(fasta_file_name);
            DigestedFastaFile df = PerformDigestion.performDigest(f, GlobalVar.NUM_MISSED_CLEAVAGES);

            int numberOfProteinsInFasta         = f.getAccessionToFullSequence().Count;
            int numberOfPeptidesInDigestedFasta = df.getDigestedPeptideArray().Count;

            log.Info("Fasta file: " + fasta_file_name);
            log.Info("Num missed cleavages: " + GlobalVar.NUM_MISSED_CLEAVAGES);
            log.Info("Number of proteins: " + numberOfProteinsInFasta);
            log.Info("Number of peptides: " + numberOfPeptidesInDigestedFasta);

            log.Debug("Constructing graph...");
            Database g;

            if (GlobalVar.isSimulationForFeatureExtraction == true)
            {
                g = new Database(f, df, true, false);
            }
            else
            {
                g = new Database(f, df, true, true);
            }
            log.Debug(g);

            return(g);
        }
Exemplo n.º 2
0
        public static Database loadExclusionDatabase(String fasta_file_name, int missedCleavages)
        {
            FastaFile         fasta;
            DigestedFastaFile digestedFasta;

            // Load fasta file
            fasta = Loader.parseFasta(fasta_file_name);

            // Digest the fasta file using peptide chainsaw
            digestedFasta = PerformDigestion.performDigest(fasta, missedCleavages);

            return(loadExclusionDatabase(fasta, digestedFasta));
        }