code: def test_parquet_column_statistics_api(
      data,
      type,
      physical_type,
      min_value,
      max_value,
      null_count,
      num_values,
      distinct_count,
  ):
      df = pd.DataFrame({"data": data})
      schema = pa.schema([pa.field("data", type)])
      table = pa.Table.from_pandas(df, schema=schema, safe=False)
      fileh = make_sample_file(table)
  
      meta = fileh.metadata
  
      rg_meta = meta.row_group(0)
      col_meta = rg_meta.column(0)
  
      stat = col_meta.statistics
      assert stat.has_min_max
      assert _close(type, stat.min, min_value)
      assert _close(type, stat.max, max_value)
      assert stat.null_count == null_count
      assert stat.num_values == num_values
      # TODO(kszucs) until parquet-cpp API doesn't expose HasDistinctCount
      # method, missing distinct_count is represented as zero instead of None
      assert stat.distinct_count == distinct_count
      assert stat.physical_type == physical_type
  
imports: import datetime
  import decimal
  from collections import OrderedDict
  import io
  import numpy
  import pytest
  import pyarrow
  from pyarrow.tests.parquet.common import _check_roundtrip, make_sample_file
  from pyarrow.fs import LocalFileSystem
  from pyarrow.tests import util
label_desc: Use image node_id 3 for calling a global function with example usage: test_parquet_column_statistics_api(data, type, physical_type, min_value, max_value, null_count, num_values, distinct_count) without return types