Package jmotifx.preprocess

Examples of jmotifx.preprocess.JMotifXBlockSequenceExtractor


        ArrayList<String> blockInputBGSeqs = new ArrayList<String>();
        String inputBackgroundFile = null;
        //get type of background
        //if backgrounf type is "input", retrieve input background sequences...
        //  else,
        JMotifXBlockSequenceExtractor jmxBSXr = new  JMotifXBlockSequenceExtractor();
        String backgroundType = configMap.get("backgroundType");
        if(backgroundType.equalsIgnoreCase("input")){
            inputBackgroundFile = configMap.get("backgroudSequenceFile");
            JMotifXSequenceFileReader jmotifxR = new JMotifXSequenceFileReader();
            ArrayList<String> inputBGSeqs = jmotifxR.extractSequences(inputBackgroundFile);
            // preprocess input background sequence if not already done...
            // preprocessing at this stage involves, extracting a block sequence of the inputted sequence,
            //   presupposing the inputed peptide sequences are of variable lengths.
            blockInputBGSeqs = jmxBSXr.extractBlockSequence(inputBGSeqs, configMap, db);          
        } else if(backgroundType.equalsIgnoreCase("database")){
            //get all peptides about the specified central residue with the specified window
            blockInputBGSeqs = jmxBSXr.extractBlockSeqs4rmDBWithMotifNCentralResidue(configMap, db);         
        } else if(backgroundType.equalsIgnoreCase("random")){
            blockInputBGSeqs = jmxBSXr.extractRandomBlockSequences(configMap, db);
        }       
        return blockInputBGSeqs;
    }
View Full Code Here


        JMotifXSequenceFileReader jmotifxR = new JMotifXSequenceFileReader();
        System.out.println(" MotifXPeptideSequenceExtractor: Reading sequences from file..." + new File(inputSequenceFile).getName());
        ArrayList<String> inseqs = jmotifxR.extractSequences(inputSequenceFile);
       
        //Extract block sequences....
        JMotifXBlockSequenceExtractor bseqExt = new JMotifXBlockSequenceExtractor();
        int peptideWindow = Integer.parseInt(configMap.get("peptideWindow"));
        String centerResidue = configMap.get("centerResidue");
        ArrayList<String> inseqsBlock =
                bseqExt.extractBlockSequenceThisWindow(inseqs, peptideWindow, db, centerResidue); //window defaults to 13
       
        //Remove redundant Peptides
        MotifXPeptideSequenceFilter filter = new MotifXPeptideSequenceFilter();
        inputPeptideSequences = filter.removeRedundancy(inseqsBlock);
       
View Full Code Here

TOP

Related Classes of jmotifx.preprocess.JMotifXBlockSequenceExtractor

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.