mscore::algorithm::isotope

Function generate_isotope_pattern

Source
pub fn generate_isotope_pattern(
    lower_bound: f64,
    upper_bound: f64,
    mass: f64,
    charge: f64,
    amp: f64,
    k: usize,
    sigma: f64,
    resolution: i32,
) -> (Vec<f64>, Vec<f64>)
Expand description

generate the isotope pattern for a given mass and charge

Arguments:

  • lower_bound - lower bound of the isotope pattern
  • upper_bound - upper bound of the isotope pattern
  • mass - mass of the peptide
  • charge - charge of the peptide
  • amp - amplitude of the isotope pattern
  • k - number of isotopes to consider
  • sigma - standard deviation of the normal distribution
  • resolution - resolution of the isotope pattern

Returns:

  • (Vec<f64>, Vec<f64>) - isotope pattern

ยงExamples

use mscore::algorithm::isotope::generate_isotope_pattern;

let (mzs, intensities) = generate_isotope_pattern(1500.0, 1510.0, 3000.0, 2.0, 1e4, 10, 1.0, 3);