code: def _is_categorical(trials: list[FrozenTrial], param: str) -> bool:
      return any(
          isinstance(t.distributions[param], CategoricalDistribution)
          for t in trials
          if param in t.params
      )
  
file_path: optuna/optuna/visualization/matplotlib/_utils.py
imports: from __future__ import annotations
  from optuna._experimental import experimental_func
  from optuna.distributions import CategoricalDistribution
  from optuna.distributions import FloatDistribution
  from optuna.distributions import IntDistribution
  from optuna.trial import FrozenTrial
  from optuna.visualization.matplotlib import _matplotlib_imports
label_desc: Use image node_id 3 for calling a global function with example usage: _is_categorical(trials, param) and returns: any