PredictUsingTrend

Disponible avec une licence Image Analyst.

Synthèse

Computes a forecasted multidimensional raster object using the output trend raster from the GenerateTrend function.

Discussion

For more information about how this function works, see the Predict Using Trend raster function.

The referenced raster dataset for the raster object is temporary. To make it permanent, you can call the raster object's save method.

Syntaxe

PredictUsingTrend (raster, {dimension_definition_type}, {dimension_values}, {start}, {end}, {interval_value}, {interval_unit})
ParamètreExplicationType de données
raster

The input trend raster from the GenerateTrend function.

Raster
dimension_definition_type

Specifies the method to be used to provide prediction dimension values.

  • BY_VALUE—The prediction will be calculated for a single dimension value or a list of dimension values defined by the dimension_values argument. This is the default.
  • BY_INTERVAL—The prediction will be calculated for an interval of the dimension defined by the start and end arguments.

(La valeur par défaut est BY_VALUE)

String
dimension_values
[dimension_values,...]

The dimension value or list of values to be used in the prediction. The format of the value must match the format of the dimension in the input multidimensional raster. If the trend raster was generated for the StdTime dimension, the format will be YYYY-MM-DDTHH:MM:SS, for example, 2050-01-01T12:00:00.

This argument is required when the dimension_def parameter is set to BY_VALUE.

(La valeur par défaut est None)

String
start

The start date, height, or depth of the dimension interval to be used in the prediction. The format of the value must match the format of the dimension in the input multidimensional raster.

(La valeur par défaut est None)

String
end

The end date, height, or depth of the dimension interval to be used in the prediction. The format of the value must match the format of the dimension in the input multidimensional raster.

(La valeur par défaut est None)

String
interval_value

The number of steps between two dimension values to be included in the prediction. The default value is 1.

(La valeur par défaut est 1)

Double
interval_unit

Specifies the unit that will be used for the interval_value argument. This only applies when the dimension of analysis is a time dimension.

  • HOURS—The prediction will be calculated for each hour in the range of time described by the start, end, and interval_value arguments.
  • DAYS—The prediction will be calculated for each day in the range of time described by the start, end, and interval_value arguments.
  • WEEKS—The prediction will be calculated for each week in the range of time described by the start, end, and interval_value arguments.
  • MONTHS—The prediction will be calculated for each month in the range of time described by the start, end, and interval_value arguments.
  • YEARS—The prediction will be calculated for each year in the range of time described by the start, end, and interval_value arguments.

(La valeur par défaut est HOURS)

String
Valeur renvoyée
Type de donnéesExplication
Raster

The output raster.

Exemple de code

PredictUsingTrendRaster example

This example generates the forecasted NDVI values for each month in the year 2025.

# Import system modules
import arcpy
from arcpy.ia import *

# Check out the ArcGIS Image Analyst extension license
arcpy.CheckOutExtension("ImageAnalyst")

# Set the local variables
in_raster = "C:/Data/NDVI_Trend.crf"
dimension_def = "BY_INTERVAL"
dimension_values = "None"
start = "2025-01-01T00:00:00"
end = "2025-12-31T00:00:00"
interval_value = 1
interval_unit = "MONTHS"

# Apply PredictUsingTrendRaster function
predicted_raster = arcpy.ia.PredictusingTrend(in_raster, dimension_def, 
                        dimension_values , start, end, interval_value, interval_unit)
	
# Save the output
predicted_raster.save("C:/arcpyExamples/outputs/predicted_NDVI.crf")