code: def test_endog():
      # Tests for numpy input
      mod = RecursiveLS(endog.values, exog.values)
      res = mod.fit()
  
      # Test the RLS estimates against OLS estimates
      mod_ols = OLS(endog, exog)
      res_ols = mod_ols.fit()
      assert_allclose(res.params, res_ols.params)
  
      # Tests for 1-dim exog
      mod = RecursiveLS(endog, dta["m1"].values)
      res = mod.fit()
  
      # Test the RLS estimates against OLS estimates
      mod_ols = OLS(endog, dta["m1"])
      res_ols = mod_ols.fit()
      assert_allclose(res.params, res_ols.params)
  
imports: import os
  import numpy
  from numpy.testing import assert_allclose, assert_equal, assert_raises
  import pandas
  import pytest
  from scipy.stats import norm
  from statsmodels.datasets import macrodata
  from statsmodels.genmod.api import GLM
  from statsmodels.regression.linear_model import OLS
  from statsmodels.regression.recursive_ls import RecursiveLS
  from statsmodels.stats.diagnostic import recursive_olsresiduals
  from statsmodels.tools import add_constant
  from statsmodels.tools.eval_measures import aic, bic
  from statsmodels.tools.sm_exceptions import ValueWarning
label_desc: Use image node_id 1 for calling a global function with example usage: test_endog() without return types