ArcGIS for Desktop

  • Documentation
  • Pricing
  • Support

  • My Profile
  • Help
  • Sign Out
ArcGIS for Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS for Desktop

A complete professional GIS

ArcGIS for Server

GIS in your enterprise

ArcGIS for Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Pricing
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

Help

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • More...

VfTable

Available with Spatial Analyst license.

  • Summary
  • Discussion
  • Syntax
  • Properties
  • Code Sample

Summary

Defines the relationship between the vertical cost factor and the vertical relative moving angle with a vertical-factor graph identifying the vertical factor specified by a table file.

Discussion

The VfTable object is used in the Spatial Analyst tools Path Distance, Path Distance Allocation, and Path Distance Back Link.

The vertical factor (VF) object defines the relationship between the vertical cost factor and the vertical relative moving angle (VRMA).

VF defines the vertical difficulty encountered in moving from one cell to the next.

VRMA identifies the slope angle between the FROM or processing cell and the TO cell.

There is always a cost associated with traveling through a cell (though that cost can be very small); therefore, no negative vertical factors (VF) should be entered into the table.

All negative vertical factors at the beginning of the table are skipped until the first positive factor is encountered. The entry with the first positive factor defines the minimum vertical factor angle. Subsequent table entries are read until another negative factor is encountered, or the end of the table is reached. The last entry reached before either of these conditions was encountered defines the maximum vertical factor angle.

Syntax

 VfTable (inTable)
ParameterExplanationData Type
inTable

The inTable is an ASCII file with two columns on each line. The first column identifies the VRMA in degrees, and the second, the VF. Each line specifies a point. Two consecutive points produce a line segment in the VRMA-VF coordinate system.

The VRMAs must be input in ascending order. The VF factor for any VRMA less than the first (lowest) input value or larger than the final (largest) input will be set to infinity. An infinite VF is represented by a negative value in the ASCII table.

File

Properties

PropertyExplanationData Type
inTable
(Read and Write)

The inTable is an ASCII file with two columns on each line. The first column identifies the VRMA in degrees, and the second, the VF. Each line specifies a point. Two consecutive points produce a line segment in the VRMA-VF coordinate system.

The VRMAs must be input in ascending order. The VF factor for any VRMA less than the first (lowest) input value or larger than the final (largest) input will be set to infinity.

String

Code Sample

VfTable example 1 (Python window)

Demonstrates how to create a VfTable class and use it in the PathDistance tool within the Python window.

import arcpy
from arcpy import env
from arcpy.sa import *
env.workspace = "C:/sapyexamples/data"
myVerticalFactor = VfTable("vffile.txt")
outPathDist = PathDistance("source.shp", "costraster", "", "", "", "",
                           myVerticalFactor)
outPathDist.save("C:/sapyexamples/output/pathdistvft")
VfTable example 2 (stand-alone script)

Performs a PathDistance analysis using the VfTable class.

# Name: VfTable_Ex_02.py
# Description: Uses the VfTable object to execute the PathDistance tool.
# Requirements: Spatial Analyst Extension

# Import system modules
import arcpy
from arcpy import env
from arcpy.sa import *

# Set environment settings
env.workspace = "C:/sapyexamples/data"

# Set local variables
inSourceData = "source.shp"
inCostRaster = "costraster"

# Create the VfTable Object
inTable = "vffile.txt"
myVerticalFactor = VfTable(inTable)

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

# Execute PathDistance
outPathDist = PathDistance(inSourceData, inCostRaster, "", "", "", "",
                           myVerticalFactor)

# Save the output 
outPathDist.save("C:/sapyexamples/output/pathdistvft2")

Related Topics

  • An overview of Spatial Analyst classes
  • An overview of vertical factor classes
Feedback on this topic?

ArcGIS for Desktop

  • Home
  • Documentation
  • Pricing
  • Support

ArcGIS Platform

  • ArcGIS Online
  • ArcGIS for Desktop
  • ArcGIS for Server
  • ArcGIS for Developers
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Insiders Blog
  • User Conference
  • Developer Summit
Esri
© Copyright 2016 Environmental Systems Research Institute, Inc. | Privacy | Legal