def calc_vmin_vmax(list_xr, quant=0.01):
    """
    Calculates vmin/vmax for list of xr DataArrays. Convenient for plotting multiple subplots with same limits.
    :param list_xr: list of xarray DataArrays.
    :param quant: quantile to calculate vmin/vmax from
    :return: vmin, vmax

    Example
    -----
    >>> from negi_stuff.modules.plot.plot import calc_vmin_vmax
    >>> list_xr = []
    >>> for i in range(5):
    >>>      for data = np.random.rand(4, 5)
    >>>      locs = np.arange(5)
    >>>      times = pd.date_range('2000-01-01', periods=4)
    >>>      foo = xr.DataArray(data, coords=[times, locs], dims=['time', 'space'])
    >>>      list_xr.append(foo)
    >>> vmin, vmax = calc_vmin_vmax(list_xr)
    >>> fig, axs = plt.subplots(5)
    >>> for ax, da in zip(axs, list_xr):
    >>>      ax.plot(ax=ax, vmin=vmin, vmax=vmax)
    """
    max_v = -9e99
    min_v = 9e99
    for xa in list_xr:
        max_v = max(max_v, xa.quantile(1 - quant))
        min_v = min(min_v, xa.quantile(quant))
    return min_v, max_v