code: def make_set_param(param_name: str):
      def set_param(this, value):
          # noinspection PyProtectedMember
          return this._set(**{param_name: value})
  
      return set_param
  
imports: from typing import Any, List, Union
  from pyspark.ml.param.shared import HasInputCol, HasOutputCol, Param
  from pyspark.sql import DataFrame, SparkSession, functions, types
  from pyspark.sql.window import Window
label_desc: Use image node_id 4 for calling a global function with example usage: make_set_param(param_name) and returns: set_param, this