code: def test_offset(self):
      resp = self.resp
      data = ds.df
      offset = np.ones(len(data))
  
      formula = "apply ~ pared + public + gpa - 1"
      modf2 = OrderedModel.from_formula(
          formula, data, offset=offset, distr="probit"
      )
      resf2 = modf2.fit(method="bfgs", disp=False)
  
      resf2_params = np.asarray(resf2.params)
      resp_params = np.asarray(resp.params)
      assert_allclose(resf2_params[:3], resp_params[:3], atol=2e-4)
      assert_allclose(resf2_params[3], resp_params[3] + 1, atol=2e-4)
  
      fitted = resp.predict()
      fitted2 = resf2.predict()
      assert_allclose(fitted2, fitted, atol=2e-4)
  
      pred_ones = resf2.predict(data[:6], offset=np.ones(6))
      assert_allclose(pred_ones, fitted[:6], atol=2e-4)
  
      # check default is 0. if exog provided
      pred_zero1 = resf2.predict(data[:6])
      pred_zero2 = resf2.predict(data[:6], offset=0)
      assert_allclose(pred_zero1, pred_zero2, atol=2e-4)
  
      # compare with equivalent results frp, no-offset model
      pred_zero = resp.predict(
          data[["pared", "public", "gpa"]].iloc[:6], offset=-np.ones(6)
      )
      assert_allclose(pred_zero1, pred_zero, atol=2e-4)
  
      params_adj = resp.params.copy()
      params_adj.iloc[3] += 1
      fitted_zero = resp.model.predict(params_adj)
      assert_allclose(pred_zero1, fitted_zero[:6], atol=2e-4)
  
imports: import warnings
  import numpy
  from numpy.testing import assert_allclose, assert_equal
  import pandas
  import pytest
  import scipy.stats
  from statsmodels.discrete.discrete_model import Logit
  from statsmodels.miscmodels.ordinal_model import OrderedModel
  from statsmodels.tools.sm_exceptions import HessianInversionWarning
  from statsmodels.tools.tools import add_constant
  from .results.results_ordinal_model import data_store
label_desc: Use image node_id 4 for calling the TestProbitModel obj's underlying member method code with example usage: obj.test_offset() without return types