code: def test_is_invertible():
      # Tests for the `is_invertible` property
      spec = specification.SARIMAXSpecification(
          order=(1, 1, 1), seasonal_order=(1, 1, 1, 4)
      )
      p = params.SARIMAXParams(spec=spec)
  
      # Test invertibility
      assert_raises(ValueError, p.__getattribute__, "is_invertible")
      p.ma_params = [0.5]
      p.seasonal_ma_params = [0]
      assert_(p.is_invertible)
      p.ma_params = [1.0]
      assert_(not p.is_invertible)
  
      p.ma_params = [0]
      p.seasonal_ma_params = [0.5]
      assert_(p.is_invertible)
      p.seasonal_ma_params = [1.0]
      assert_(not p.is_invertible)
  
      p.ma_params = [0.2]
      p.seasonal_ma_params = [0.2]
      assert_(p.is_invertible)
      p.ma_params = [0.99]
      p.seasonal_ma_params = [0.99]
      assert_(p.is_invertible)
      p.ma_params = [1.0]
      p.seasonal_ma_params = [1.0]
      assert_(not p.is_invertible)
  
file_path: statsmodels/statsmodels/tsa/arima/tests/test_params.py
imports: import numpy
  import pandas
  from numpy.testing import assert_, assert_equal, assert_allclose, assert_raises
  from statsmodels.tsa.arima import specification, params
label_desc: Use image node_id 9 for calling a global function with example usage: test_is_invertible() without return types