def calcMhFromMz(mz, charge):
    """Calculate the MH+ value from mz and charge.

    :param mz: float, mass to charge ratio (Dalton / charge)
    :param charge: int, charge state

    :returns: mass to charge ratio of the mono protonated ion (charge = 1)
    """
    mh = (mz * charge) - (maspy.constants.atomicMassProton * (charge-1) )
    return mh
def calcMhFromMz ( mz , charge ) : mh = ( mz * charge ) - ( maspy . constants . atomicMassProton * ( charge - 1 ) ) return mh
Calculate the MH+ value from mz and charge.

    :param mz: float, mass to charge ratio (Dalton / charge)
    :param charge: int, charge state

    :returns: mass to charge ratio of the mono protonated ion (charge = 1)