Exemplo n.º 1
0
        private PeakData buildPeak(List<XICDataPoint> xicPoints, int numPeakPoints, int cursor)
        {
            if (cursor + numPeakPoints >= xicPoints.Count)
                return null;

            PeakData peak = new PeakData(numPeakPoints*2 + 1);

            var peakIndex = 0;
            //for (int index = cursor - numPeakPoints; index <= cursor + numPeakPoints; index++)
            //{
            //    peak.AddPeak(peakIndex, xicPoints[index].scanNumber, xicPoints[index].intensity);
            //}

            int startPeakCursor = cursor - numPeakPoints;
            for (peakIndex = 0; peakIndex <= 2*numPeakPoints; peakIndex++)
            {
                peak.AddPeak(peakIndex, xicPoints[startPeakCursor+peakIndex].scanNumber, xicPoints[startPeakCursor + peakIndex].intensity);
            }

            return peak;
        }
Exemplo n.º 2
0
        private List<PeakData> GetDummyPeaks()
        {
            List<PeakData> peakList = new List<PeakData>();
            PeakData peak = new PeakData(10, 20, new double[] { 23.4, 24.5, 27.8, 29.7, 23.4, 24.5, 27.8, 29.7, 27.8, 29.7 });
            peakList.Add(peak);
            peak = new PeakData(20, 22, new double[] { 29.7, 23.4, 24.5 });
            peakList.Add(peak);

            return peakList;
        }