private static DataTypes.Spectrum getSpectrum(IFXStore xyStore, IFXData data) { DataTypes.Spectrum spectrum = new DataTypes.Spectrum(); List <DataTypes.IPeak> peaks = new List <DataTypes.IPeak>(); for (int i = 0; i < data.Count; i++) { DataTypes.IPeak peak = new DataTypes.Peak(); peak.X = Math.Round(xyStore.GetX(i), 5); peak.Y = xyStore.GetY(i) / 100000; //peak.Name = vals.ElementAt(ind) as string; peaks.Add(peak); } spectrum.Peaks = peaks; spectrum.Name = data.Title; return(spectrum); }
private static DataTypes.Chromatogram getChromatogram(IFXStore xyStore, IFXData data, double RT) { DataTypes.Chromatogram chromatogram = new DataTypes.Chromatogram(); List <DataTypes.DataPoint> peaks = new List <DataTypes.DataPoint>(); for (int i = 0; i < data.Count; i++) { DataTypes.DataPoint peak = new DataTypes.DataPoint(); peak.X = Math.Round(xyStore.GetX(i), 5); peak.Y = xyStore.GetY(i) / 100000; //peak.Name = vals.ElementAt(ind) as string; peaks.Add(peak); } chromatogram.Data = peaks; chromatogram.Name = RT.ToString(); chromatogram.Title = data.Title; return(chromatogram); }