code: def test_score_test_2indep():
      # this does not verify the statistic and pvalue yet
      count1, nobs1 = 7, 34
      count2, nobs2 = 1, 34
  
      for co in ["diff", "ratio", "or"]:
          res = score_test_proportions_2indep(
              count1, nobs1, count2, nobs2, compare=co
          )
          assert_allclose(res.prop1_null, res.prop2_null, rtol=1e-10)
  
          # check that equality case is handled
          val = 0 if co == "diff" else 1.0
          s0, pv0 = score_test_proportions_2indep(
              count1,
              nobs1,
              count2,
              nobs2,
              compare=co,
              value=val,
              return_results=False,
          )[:2]
          s1, pv1 = score_test_proportions_2indep(
              count1,
              nobs1,
              count2,
              nobs2,
              compare=co,
              value=val + 1e-10,
              return_results=False,
          )[:2]
          assert_allclose(s0, s1, rtol=1e-8)
          assert_allclose(pv0, pv1, rtol=1e-8)
          s1, pv1 = score_test_proportions_2indep(
              count1,
              nobs1,
              count2,
              nobs2,
              compare=co,
              value=val - 1e-10,
              return_results=False,
          )[:2]
          assert_allclose(s0, s1, rtol=1e-8)
          assert_allclose(pv0, pv1, rtol=1e-8)
  
imports: import warnings
  import numpy
  from numpy.testing import assert_allclose, assert_almost_equal, assert_array_less, assert_equal, assert_raises
  import pandas
  import pytest
  import statsmodels.stats.proportion
  from statsmodels.stats.proportion import confint_proportions_2indep, multinomial_proportions_confint, power_proportions_2indep, proportion_confint, samplesize_proportions_2indep_onetail, score_test_proportions_2indep
  from statsmodels.tools.sm_exceptions import HypothesisTestWarning
  from statsmodels.tools.testing import Holder
  from statsmodels.stats.tests.results.results_proportion import res_binom, res_binom_methods
label_desc: Use image node_id 18 for calling a global function with example usage: test_score_test_2indep() without return types