%% Function for plotting a mass spectrum
function plot_spectrum(spec, label)
    if label == 'Benign'
        plot(spec.M_Z, spec.Intensity, 'b')
    else 
        plot(spec.M_Z, spec.Intensity, 'r')
    end
    xlabel ('M/Z');
    ylabel ('Intensity');
    grid();
    legend(label);
end