def updateParameters(self, parameters):

        zone_parameter = parameters[0]
        input_parameter = parameters[1]
        variable_parameter = parameters[2]
        output_parameter = parameters[3]
        type_parameter = parameters[4]
        ignore_parameter = parameters[5]
        zonefield_parameter = parameters[6]

        # Populate the output netCDF file parameter with a reasonable default
        # (i.e. the name of the variable with 'zonal_' appended to it.)
        if (variable_parameter.value is not None) and (not output_parameter.altered):
            out_file_name = variable_parameter.valueAsText + '_zonal'
            # Generate a unique name
            i = 1
            temp_name = out_file_name + '.nc'
            while arcpy.Exists(temp_name):
                temp_name = out_file_name + str(i) + '.nc'
                i += 1
            out_file_name = temp_name
            # Up-level the default workspace to a folder
            workspace = arcpy.env.workspace
            while arcpy.Describe(workspace).datatype != "Folder":
                workspace = os.path.dirname(workspace)
            output_parameter.value = os.path.join(workspace, out_file_name)

        # Set zone parameter default
        if (zone_parameter.value is not None) and (not zonefield_parameter.altered):
            valid_raster_types = ["RasterLayer", "RasterDataset"]
            valid_feature_types = ["ShapeFile","FeatureLayer", "FeatureDataset"]
            desc = arcpy.Describe(zone_parameter.value)
            if desc.dataType in valid_raster_types:
                zonefield_parameter.value = "Value"
            else:
                zonefield_parameter.value = "FID"

        return
Modifies the values and properties of parameters before internal
dataset/ETHPy150Open Esri/solutions-geoprocessing-toolbox/suitability/toolboxes/scripts/MultidimensionSupplementalTools/MultidimensionSupplementalTools/Scripts/mds/tools/multidimensional_zonal_statistics.py/MultidimensionalZonalStatistics.updateParameters