code: def recommend_lowercase_d(data: pd.Series, **kwargs) -> int:
      """Returns the recommended value of differencing order 'd' to use
  
      Parameters
      ----------
      data : pd.Series
          The data for which the differencing order needs to be calculated
  
      *kwargs: Keyword arguments that can be passed to the difference test.
          Values are:
              alpha : float, optional
                  Significance Value, by default 0.05
              test : str, optional
                  The test to use to test the order of differencing, by default 'kpss'
              max_d : int, optional
                  maximum differencing order to try, by default 2
  
      Returns
      -------
      int
          The differencing order to use
      """
      recommended_lowercase_d = ndiffs(data, **kwargs)
      return recommended_lowercase_d
  
imports: from typing import Dict, List, Optional, Tuple, Union
  import numpy
  import pandas
  import statsmodels.api
  from pmdarima.arima.utils import ndiffs, nsdiffs
  from statsmodels.tools.sm_exceptions import MissingDataError
  from statsmodels.tsa.api import kpss
  from statsmodels.tsa.stattools import adfuller
  from pycaret.internal.logging import get_logger
  from pycaret.internal.tests import _format_test_results
  from pycaret.internal.tests.stats import _is_gaussian, _summary_stats
  from pycaret.utils.time_series import _get_diff_name_list
  from pycaret.utils.time_series.exceptions import MissingDataError
label_desc: Use image node_id 9 for calling a global function with example usage: recommend_lowercase_d(data) and returns: recommended_lowercase_d