code: def df_corr(df, method="pearson", min_periods=1):
      """
      Compute pairwise correlation of columns, excluding NA/null values.
  
      Parameters
      ----------
      method : {'pearson', 'kendall', 'spearman'} or callable
          Method of correlation:
  
          * pearson : standard correlation coefficient
          * kendall : Kendall Tau correlation coefficient
          * spearman : Spearman rank correlation
          * callable: callable with input two 1d ndarrays
              and returning a float. Note that the returned matrix from corr
              will have 1 along the diagonals and will be symmetric
              regardless of the callable's behavior.
  
          .. note::
              kendall, spearman and callables not supported on multiple chunks yet.
  
      min_periods : int, optional
          Minimum number of observations required per pair of columns
          to have a valid result. Currently only available for Pearson
          and Spearman correlation.
  
      Returns
      -------
      DataFrame
          Correlation matrix.
  
      See Also
      --------
      DataFrame.corrwith : Compute pairwise correlation with another
          DataFrame or Series.
      Series.corr : Compute the correlation between two Series.
  
      Examples
      --------
      >>> import mars.dataframe as md
      >>> df = md.DataFrame([(.2, .3), (.0, .6), (.6, .0), (.2, .1)],
      ...                   columns=['dogs', 'cats'])
      >>> df.corr(method='pearson').execute()
                dogs      cats
      dogs  1.000000 -0.851064
      cats -0.851064  1.000000
      """
      op = DataFrameCorr(method=method, min_periods=min_periods)
      return op(df)
  
imports: import numpy
  import pandas
  from ...None import opcodes
  from ...core import ENTITY_TYPE, recursive_tile
  from ...serialization.serializables import BoolField, AnyField, KeyField, Int32Field
  from ...tensor.utils import filter_inputs
  from ...utils import has_unknown_shape
  from ..core import SERIES_TYPE, DATAFRAME_TYPE
  from ..operands import DataFrameOperand, DataFrameOperandMixin
  from ..utils import build_empty_df, validate_axis, parse_index
label_desc: Use image node_id 2 for calling a global function with example usage: df_corr(df, method, min_periods) and returns: op