code: def check_optional_dependency(package_name: str) -> None:
      """
      Check if an optional dependency is installed, if not raise an ImportError
      with installation instructions.
  
      Parameters
      ----------
      package_name : str
          Name of the package to check.
  
      Returns
      -------
      None
  
      """
  
      if importlib.util.find_spec(package_name) is None:
          try:
              extra, package_version = _find_optional_dependency(
                  package_name=package_name
              )
              msg = (
                  f"\n'{package_name}' is an optional dependency not included in the default "
                  f'skforecast installation. Please run: `pip install "{package_version}"` to install it.'
                  f"\n\nAlternately, you can install it by running `pip install skforecast[{extra}]`"
              )
          except:
              msg = f"\n'{package_name}' is needed but not installed. Please install it."
  
          raise ImportError(msg)
  
imports: from typing import Union, Any, Optional, Tuple, Callable
  import warnings
  import importlib
  import joblib
  import numpy
  import pandas
  import sklearn
  import sklearn.pipeline
  import sklearn.linear_model
  from sklearn.compose import ColumnTransformer
  from sklearn.exceptions import NotFittedError
  import inspect
  from copy import deepcopy
  import skforecast
  from ..exceptions import MissingValuesExogWarning
  from ..exceptions import DataTypeWarning
  from ..exceptions import IgnoredArgumentWarning
  from ..exceptions import SkforecastVersionWarning
label_desc: Use image node_id 23 for calling a global function with example usage: check_optional_dependency(package_name) without return types