code: def _get_example_value_presence_as_dataframe(
      record_batch: pa.RecordBatch,
      path: types.FeaturePath,
      boundaries: Optional[Sequence[float]],
      weight_column_name: Optional[Text],
  ) -> Optional[pd.DataFrame]:
      value_presence = lift_stats_generator._get_example_value_presence(
          record_batch, path, boundaries, weight_column_name
      )
      if not value_presence:
          return
      df = pd.DataFrame(
          {
              "example_indices": value_presence.example_indices,
              "values": value_presence.values,
              "weights": value_presence.weights,
          }
      )
      return df.set_index("example_indices")
  
imports: from typing import Optional, Sequence, Text
  from absl.testing import absltest
  import apache_beam
  import numpy
  import pandas
  import pyarrow
  from tensorflow_data_validation import types
  from tensorflow_data_validation.statistics.generators import lift_stats_generator
  from tensorflow_data_validation.utils import test_util
  from tensorflow_data_validation.utils.example_weight_map import ExampleWeightMap
  from google.protobuf import text_format
  from tensorflow_metadata.proto.v0 import schema_pb2
  from tensorflow_metadata.proto.v0 import statistics_pb2
label_desc: Use image node_id 1 for calling a global function with example usage: _get_example_value_presence_as_dataframe(record_batch, path, boundaries, weight_column_name) and returns: df