public static float GetGlycopeptideMZ(string argPeptide, GlycanStructure argGlycan, int argCharge) { float TotalMZ = 0.0f; AminoAcidMass AAMS = new AminoAcidMass(); float PeptideMonoMass = AAMS.GetAVGMonoMW(argPeptide, true); float GlycanMass = 0.0f; GlycanMass = GlycanMass + argGlycan.NoOfHex*GlycoLib.GlycanMass.GetGlycanAVGMass(Glycan.Type.Hex); GlycanMass = GlycanMass + argGlycan.NoOfHexNac * GlycoLib.GlycanMass.GetGlycanAVGMass(Glycan.Type.HexNAc); GlycanMass = GlycanMass + argGlycan.NoOfDeHex * GlycoLib.GlycanMass.GetGlycanAVGMass(Glycan.Type.DeHex); GlycanMass = GlycanMass + argGlycan.NoOfNeuAc * GlycoLib.GlycanMass.GetGlycanAVGMass(Glycan.Type.NeuAc); GlycanMass = GlycanMass + argGlycan.NoOfNeuGc * GlycoLib.GlycanMass.GetGlycanAVGMass(Glycan.Type.NeuGc); TotalMZ = (PeptideMonoMass + GlycanMass + MassLib.Atoms.ProtonMass*argCharge)/argCharge; return TotalMZ; }
private void btnGetPeptideMass_Click(object sender, EventArgs e) { AminoAcidMass AAMS = new AminoAcidMass(); lblPeptideMass.Text = " Mass:" + AAMS.GetMonoMW(txtPeptideSeq.Text, chkCYS_CAM.Checked) + "\nAvg Mass:" + AAMS.GetAVGMonoMW(txtPeptideSeq.Text, chkCYS_CAM.Checked); }