class_docstr: This module applies functions to specified feature and metrics.
  
  Extra parameters (kwargs) can be passed to the apply function.
docstr: Add function to be applied to dataframe.
  
  Can call this function after module instantiation to add new functions.
  
  :param func: function to apply
  :param suffix: (string, optional) suffix added to each metric. default is function name.
  :param prefix: (string, optional) prefix added to each metric.
  :param features: (list, optional) features the function is applied to. Overwrites features above
  :param metrics: (list, optional) metrics the function is applied to. Overwrites metrics above
  :param entire: (boolean, optional) apply function to the entire feature's dataframe of metrics?
  :param args: (tuple, optional) args for 'func'
  :param kwargs: (dict, optional) kwargs for 'func'
docstr_tok: ["Add","function","to","be","applied","to","dataframe",".","Can","call","this","function","after","module","instantiation","to","add","new","functions",".",":","param","func",":","function","to","apply",":","param","suffix",":","(","string",",","optional",")","suffix","added","to","each","metric",".","default","is","function","name",".",":","param","prefix",":","(","string",",","optional",")","prefix","added","to","each","metric",".",":","param","features",":","(","list",",","optional",")","features","the","function","is","applied","to",".","Overwrites","features","above",":","param","metrics",":","(","list",",","optional",")","metrics","the","function","is","applied","to",".","Overwrites","metrics","above",":","param","entire",":","(","boolean",",","optional",")","apply","function","to","the","entire","feature","'s","dataframe","of","metrics","?",":","param","args",":","(","tuple",",","optional",")","args","for","'func'",":","param","kwargs",":","(","dict",",","optional",")","kwargs","for","'func","'"]
code: def add_apply_func(
      self,
      func,
      suffix=None,
      prefix=None,
      metrics=None,
      features=None,
      entire=None,
      *args,
      **kwargs,
  ):
      """Add function to be applied to dataframe.
  
      Can call this function after module instantiation to add new functions.
  
      :param func: function to apply
      :param suffix: (string, optional) suffix added to each metric. default is function name.
      :param prefix: (string, optional) prefix added to each metric.
      :param features: (list, optional) features the function is applied to. Overwrites features above
      :param metrics: (list, optional) metrics the function is applied to. Overwrites metrics above
      :param entire: (boolean, optional) apply function to the entire feature's dataframe of metrics?
      :param args: (tuple, optional) args for 'func'
      :param kwargs: (dict, optional) kwargs for 'func'
      """
      # check inputs
      if features is None:
          features = []
      if metrics is None:
          metrics = []
      if not callable(func):
          raise TypeError(
              "functions in ApplyFunc must be callable objects"
          )
      if suffix is not None and not isinstance(suffix, str):
          raise TypeError(
              "prefix, and suffix in ApplyFunc must be strings or None."
          )
      if prefix is not None and not isinstance(prefix, str):
          raise TypeError(
              "prefix, and suffix in ApplyFunc must be strings or None."
          )
      if not isinstance(metrics, list) or not isinstance(
          features, list
      ):
          raise TypeError(
              "metrics and features must be lists of strings."
          )
  
      # add function
      self.apply_funcs.append(
          {
              "features": features,
              "metrics": metrics,
              "func": func,
              "entire": entire,
              "suffix": suffix,
              "prefix": prefix,
              "args": args,
              "kwargs": kwargs,
          }
      )
  
file_path: popmon/popmon/analysis/apply_func.py
imports: from __future__ import annotations
  import warnings
  import numpy
  import pandas
  from popmon.base import Module
  from popmon.utils import parallel
label_desc: Use image node_id 3 for calling the ApplyFunc obj's underlying member method code with example usage: obj.add_apply_func(func, suffix, prefix, metrics, features, entire) without return types