code: def test_numba_rhat(method):
      """Numba test for mcse."""
      state = Numba.numba_flag
      school = np.random.rand(100, 100)
      Numba.disable_numba()
      non_numba = rhat(school, method=method)
      Numba.enable_numba()
      with_numba = rhat(school, method=method)
      assert np.allclose(with_numba, non_numba)
      assert Numba.numba_flag == state
  
file_path: arviz/arviz/tests/base_tests/test_diagnostics_numba.py
imports: import importlib
  import numpy
  import pytest
  from ...data import load_arviz_data
  from ...rcparams import rcParams
  from ...stats import bfmi, mcse, rhat
  from ...stats.diagnostics import _mc_error, ks_summary
  from ...utils import Numba
  from ..helpers import running_on_ci
  from .test_diagnostics import data
label_desc: Use image node_id 2 for calling a global function with example usage: test_numba_rhat(method) without return types