code: def check_numpy2d_table(obj, return_metadata=False, var_name="obj"):
      metadata = dict()
  
      if not isinstance(obj, np.ndarray):
          msg = f"{var_name} must be a numpy.ndarray, found {type(obj)}"
          return _ret(False, msg, None, return_metadata)
  
      if len(obj.shape) != 2:
          msg = f"{var_name} must be 1D or 2D numpy.ndarray, but found {len(obj.shape)}D"
          return _ret(False, msg, None, return_metadata)
  
      # we now know obj is a 2D np.ndarray
      if _req("is_empty", return_metadata):
          metadata["is_empty"] = len(obj) < 1 or obj.shape[1] < 1
      if _req("is_univariate", return_metadata):
          metadata["is_univariate"] = obj.shape[1] < 2
      if _req("n_instances", return_metadata):
          metadata["n_instances"] = obj.shape[0]
      # check whether there any nans; compute only if requested
      if _req("has_nans", return_metadata):
          metadata["has_nans"] = pd.isnull(obj).any()
  
      return _ret(True, None, metadata, return_metadata)
  
imports: import numpy
  import pandas
  from sktime.datatypes._common import _req, _ret
label_desc: Use image node_id 4 for calling a global function with example usage: check_numpy2d_table(obj, return_metadata, var_name) and returns: _ret, _ret, _ret