def setRange(ax, style):
    """Re-scales the plot to the range stated on the 'style' element.

    Parameters
    ----------
    ax : Matplotlib axes
        Can be obtained from a figure with: fig.get_axes()[0]
    style : Plot-style dictionary.
        Should contain:
            style['xRange'] = (lo, hi)
            style['yRange'] = (lo, hi)

    Returns
    -------
    ax
        Returns the changed ax with the modification performed.

    """
    ax.set_xlim(style['xRange'][0], style['xRange'][1])
    ax.set_ylim(style['yRange'][0], style['yRange'][1])
    return ax
