Package org.bmdrc.mass

Examples of org.bmdrc.mass.PeakList


    public void setPeakList(PeakList thePeakList) {
        this.itsPeakList = thePeakList;
    }

    public PeakList setPeakList() {
        this.itsPeakList = new PeakList();
        return itsPeakList;
    }
View Full Code Here


    }

    private PeakList __openFile(File theInputFile, String theColumnSeparator) throws FileNotFoundException, IOException {
        BufferedReader theFileReader = new BufferedReader(new FileReader(theInputFile));
        String theFileString = new String();
        PeakList thePeakList = new PeakList();

        while ((theFileString = theFileReader.readLine()) != null) {
            String[] theSplitedString = theFileString.split(theColumnSeparator);

            thePeakList.addPeak(new PeakUnit(Double.parseDouble(theSplitedString[this.MW_INDEX]), Double.parseDouble(theSplitedString[this.INTENSITY_INDEX]), theInputFile.toString()));
        }

        return thePeakList;
    }
View Full Code Here

        return this.generateCommonPeak2dList();
    }

    public List<PeakList> generateCommonPeak2dList() {
        PeakList theTotalPeakList = this.__getTotalPeakList();
       
        this.setCommonPeak2dList(new ArrayList<PeakList>());

        for (int pi = 0, pEnd = theTotalPeakList.size() - this.getPeak2dList().size(); pi <= pEnd; pi++) {
            PeakList theCommonPeakList = this.__getCommonPeakList(theTotalPeakList, pi, this.getPeak2dList().size());
           
            if (!this.__containsSameList(this.getCommonPeak2dList(), theCommonPeakList)) {
                this.__generateCommonPeak2dList(theCommonPeakList, this.getPeak2dList().size());
            }
        }
View Full Code Here

        return true;
    }

    private PeakList __getCommonPeakList(PeakList thePeakList, int theStartIndex, int theNumberOfFile) {
        PeakList theCommonPeakList = new PeakList();

        for (int pi = theStartIndex, pEnd = theStartIndex + theNumberOfFile; pi < pEnd; pi++) {
            theCommonPeakList.addPeak(thePeakList.get(pi));
        }

        return theCommonPeakList;
    }
View Full Code Here

        return theMaximumWeight - theMinimumWeight < this.getTolerence();
    }

    private PeakList __getTotalPeakList() {
        PeakList theTotalPeakList = new PeakList();

        for (PeakList thePeakList : this.getPeak2dList()) {
            theTotalPeakList.addAll(thePeakList);
        }

        theTotalPeakList.sort();

        return theTotalPeakList;
    }
View Full Code Here

    }

    private PeakList __openFile(File theInputFile, String theColumnSeparator) throws FileNotFoundException, IOException {
        BufferedReader theFileReader = new BufferedReader(new FileReader(theInputFile));
        String theFileString = new String();
        PeakList thePeakList = new PeakList();

        while ((theFileString = theFileReader.readLine()) != null) {
            String[] theSplitedString = theFileString.split(theColumnSeparator);

            thePeakList.addPeak(new PeakUnit(Double.parseDouble(theSplitedString[this.MW_INDEX]), Double.parseDouble(theSplitedString[this.INTENSITY_INDEX]), theInputFile.toString()));
        }

        return thePeakList;
    }
View Full Code Here

        return this.generateCommonPeak2dList();
    }

    public List<PeakList> generateCommonPeak2dList() {
        PeakList theTotalPeakList = this.__getTotalPeakList();
       
        this.setCommonPeak2dList(new ArrayList<PeakList>());

        for (int pi = 0, pEnd = theTotalPeakList.size() - this.getPeak2dList().size(); pi <= pEnd; pi++) {
            PeakList theCommonPeakList = this.__getCommonPeakList(theTotalPeakList, pi, this.getPeak2dList().size());
           
            if (!this.__containsSameList(this.getCommonPeak2dList(), theCommonPeakList)) {
                this.__generateCommonPeak2dList(theCommonPeakList, this.getPeak2dList().size());
            }
        }
View Full Code Here

        return true;
    }

    private PeakList __getCommonPeakList(PeakList thePeakList, int theStartIndex, int theNumberOfFile) {
        PeakList theCommonPeakList = new PeakList();

        for (int pi = theStartIndex, pEnd = theStartIndex + theNumberOfFile; pi < pEnd; pi++) {
            theCommonPeakList.addPeak(thePeakList.get(pi));
        }

        return theCommonPeakList;
    }
View Full Code Here

        return theMaximumWeight - theMinimumWeight < this.getTolerence();
    }

    private PeakList __getTotalPeakList() {
        PeakList theTotalPeakList = new PeakList();

        for (PeakList thePeakList : this.getPeak2dList()) {
            theTotalPeakList.addAll(thePeakList);
        }

        theTotalPeakList.sort();

        return theTotalPeakList;
    }
View Full Code Here

    public PeakList getOriginalPeakList() {
        return itsOriginalPeakList;
    }

    public void setOriginalPeakList(PeakList theOriginalPeakList) {
        this.itsOriginalPeakList = new PeakList(theOriginalPeakList);
    }
View Full Code Here

TOP

Related Classes of org.bmdrc.mass.PeakList

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.