/// <summary> /// Add the Cit Spectra to quantification. /// </summary> /// <param name="scoredSpectra">The spectra to be added.</param> private static void AddCitSpectraAboveCutoffToQuantification(Dictionary <XTSpectrum, List <XTSpectrum> > scoredSpectra) { // Loop through all of the spectra foreach (KeyValuePair <XTSpectrum, List <XTSpectrum> > spectrum in scoredSpectra) { // Check that the CitScore is greater than the CutOff value if (spectrum.Key.CitScore >= ScoreSettings.CutOffScore) { // If the spectrum passes, add the spectrum to the quantification together with the complementary spectrum with the highest match score Quantification.AddTokvpCitSpecSpecDict(spectrum.Key, spectrum.Value[0]); // Add the spectrum ID to the list Validation.citChosenForQuantList.Add(spectrum.Key.ID); } } }
/// <summary> /// Add the spectrum to quantification. /// </summary> private void MetroButtonAddQuant_Click(object sender, EventArgs e) { // Get the spectra XTSpectrum spectrumCit = valKVP.Key; XTSpectrum spectrumArg = valKVP.Value[argIndex]; // Add the spectrum to the dictionary Quantification.AddTokvpCitSpecSpecDict(spectrumCit, spectrumArg); // Update the quantification id list UpdateChosenForQuant(valKVP.Key.ID, true); // Prevent moving back and forth through the complementary spectra metroButtonNextArgScan.Enabled = false; metroButtonPrevArgScan.Enabled = false; // Enable and disable the button metroButtonAddQuant.Enabled = false; metroButtonRemoveQuant.Enabled = true; }