def guessAperFromLocn(life_adj, aperypos):
    """Infer which aperture was in use from the aperture position.

    Parameters
    ----------
    life_adj: int or "N/A"
        Integer code for the "lifetime position," or "N/A" if the LIFE_ADJ
        keyword was not found in the header.

    aperypos: float or "N/A"
        Location (in steps) of the aperture block, or "N/A" if the keyword
        was not found in the header.

    Returns
    -------
    aperture: str or None
        An educated guess as to which aperture was in use, either "PSA" or
        "BOA".  None will be returned if the input arguments were not
        sufficient for determining the aperture.
    """
    if life_adj == 1:
        if 116.0 < aperypos and aperypos < 136.0:
            aperture = 'PSA'
        elif -163.0 < aperypos and aperypos < -143.0:
            aperture = 'BOA'
        else:
            aperture = None
    elif life_adj == 2:
        if 52.0 < aperypos and aperypos < 72.0:
            aperture = 'PSA'
        elif -227.0 < aperypos and aperypos < -207.0:
            aperture = 'BOA'
        else:
            aperture = None
    else:
        aperture = None
    return aperture
