This tool truncates the values in an input image to the desired number of decimal places. Use the Round tool if you would prefer to round the values in the input image to the nearest whole number. NoData values in either of the input images will be assigned NoData values in the output image.
The following is an example of a Python script that uses this tool:
wd = pluginHost.getWorkingDirectory()
inputFile = wd + "input.dep"
decimalPlaces = "2"
outputFile = wd + "output.dep"
args = [inputFile, decimalPlaces, outputFile]
pluginHost.runPlugin("Truncate", args, False)
This is a Groovy script also using this tool:
def wd = pluginHost.getWorkingDirectory()
def inputFile = wd + "input.dep"
def decimalPlaces = "2"
def outputFile = wd + "output.dep"
String[] args = [inputFile, decimalPlaces, outputFile]
pluginHost.runPlugin("Truncate", args, false)