Can you please write me sample loop that iterate through prepared earlier values and automatically changes number of output raster e.g. from outDirectRad1 to outDirectRad2.
Parameters that will change on each iteration:
e.g. first iteration
timeConfig = TimeMultipleDays(2015, 2, 32)
diffuseProp = 0.6
transmittivity = 0.2
e.g. second iteration
timeConfig = TimeMultipleDays(2015, 1, 31)
diffuseProp = 0.4
transmittivity = 0.3
**
- Rest parameters are the same in each iteration
**
Here is my code:
import arcpy
from arcpy import env
from arcpy.sa import *
env.workspace = "C:/xxx/output"
arcpy.CheckOutExtension("Spatial")
inRaster = "C:/xxx/output/Test"
latitude = 47.04
skySize = 200
timeConfig = TimeMultipleDays(2015, 2, 32)
dayInterval = 14
hourInterval = 1
zFactor = 1
calcDirections = 32
zenithDivisions = 8
azimuthDivisions = 8
diffuseProp = 0.4
transmittivity = 0.6
outDirectRad = "C:/xxx/output/outDirectRad1"
outDiffuseRad = "C:/xxx/output/outDiffuseRad1"
outDirectDur = "C:/xxx/output/dir_dur1"
globRad1 = AreaSolarRadiation(inRaster, latitude, skySize, timeConfig,
dayInterval, hourInterval, "NOINTERVAL", zFactor, "FROM_DEM",
calcDirections, zenithDivisions, azimuthDivisions, "UNIFORM_SKY",
diffuseProp, transmittivity, outDirectRad, outDiffuseRad, outDirectDur)
globRad1.save("C:/xxx/output")