private List <double> CreateSVMMatrices() { List <double> matrixes = new List <double>(); int Peptide = 0; if (PeptideSequence != null && PeptideSequence != "") { Peptide = 1; } int fuc = 1; int CoreYPeaks = CoreIDPeak.Count; float CoreYScore = CoreScore; if (!IUPACString.EndsWith("(DeHex-)HexNAc")) { CoreYPeaks = CoreIDPeak.Count - CoreIDPeak.Where(x => x.Item2.Contains("deHex")).ToList().Count; foreach (var core in CoreIDPeak.Where(x => x.Item2.EndsWith("(DeHex-)HexNAc"))) { CoreYScore -= core.Item1.Intensity; } fuc = 0; } matrixes.Add(Peptide); matrixes.Add(fuc); matrixes.Add(NoOfTotalGlycan); matrixes.Add(Convert.ToDouble(PPM.ToString("0.000"))); //matrixes.Add(CoreYPeaks); //matrixes.Add(Convert.ToDouble(CoreYScore.ToString("0.000"))); matrixes.Add(BranchIDPeak.Count); matrixes.Add(Convert.ToDouble(BranchScore.ToString("0.000"))); var CorePeaks = CoreIDPeak.Where(x => x.Item2 == "HexNAc").ToList(); matrixes.Add(Convert.ToDouble(CorePeaks.Count != 0 ? CorePeaks[0].Item1.Intensity.ToString("0.0000") : "0")); CorePeaks = CoreIDPeak.Where(x => x.Item2 == "HexNAc-HexNAc").ToList(); matrixes.Add(Convert.ToDouble(CorePeaks.Count != 0 ? CorePeaks[0].Item1.Intensity.ToString("0.0000") : "0")); CorePeaks = CoreIDPeak.Where(x => x.Item2 == "HexNAc-HexNAc-Hex").ToList(); matrixes.Add(Convert.ToDouble(CorePeaks.Count != 0 ? CorePeaks[0].Item1.Intensity.ToString("0.0000") : "0")); CorePeaks = CoreIDPeak.Where(x => x.Item2 == "HexNAc-HexNAc-Hex-Hex").ToList(); matrixes.Add(Convert.ToDouble(CorePeaks.Count != 0 ? CorePeaks[0].Item1.Intensity.ToString("0.0000") : "0")); CorePeaks = CoreIDPeak.Where(x => x.Item2 == "HexNAc-HexNAc-Hex-(Hex-)Hex").ToList(); matrixes.Add(Convert.ToDouble(CorePeaks.Count != 0 ? CorePeaks[0].Item1.Intensity.ToString("0.0000") : "0")); //if (MatchWithPrecursorMW) //{ // matrixes.Add(1); //} //else //{ // matrixes.Add(0); //} return(matrixes); }