code: def test_fdr_control(p_value, ind, fdr, expected):
      df = pd.DataFrame({"p_value": p_value})
      method = "fdr_bh" if ind else "fdr_by"
      df["relevant"] = multipletests(
          pvals=df.p_value, alpha=fdr, method=method
      )[0]
      result = df["relevant"].values
      expected = np.array(expected)
      assert (result == expected).all()
  
imports: import numpy
  import pandas
  import pytest
  from statsmodels.stats.multitest import multipletests
label_desc: Use image node_id 1 for calling a global function with example usage: test_fdr_control(p_value, ind, fdr, expected) without return types