def pick_share(share, ii, jj, axs_):
    """
    Helper function for selecting which axes to link. Should be called separately for sharex and sharey.

    :param share: string
        What type of sharing is going on?

    :param ii, jj: ints
        Coordinates of current plot in plot grid

    :param axs_: 2D array of Axes instances
        The plot Axes

    :return: Axes instance or None
        The Axes instance to be linked.
    """
    if share in ['all', True] and ((ii > 0) or (jj > 0)):
        return axs_[0, 0]
    elif share in ['col'] and ii > 0:
        return axs_[0, jj]
    elif share in ['row'] and jj > 0:
        return axs_[ii, 0]
    else:
        return None