Strip Map Index Features (Cartography)
Summary
Creates a series of rectangular polygons, or index features, that follow a single linear feature or a group of linear features. These index features can be used with Data Driven Pages to define pages within a strip map, or set of maps that follow a linear feature. The resulting index features contain attributes that can be used to rotate and orient the map on the page and determine which index features, or pages, are next to the current page (to the left and right or to the top and bottom).
Usage
The coordinate system of the ouput feature class is determined in this order:
- If a coordinate system is specified by the Output Coordinate System variable in the Environment Settings the output feature class will use this coordinate system.
- If a coordinate system is not specified by the Output Coordinate System the ouput feature class will use the coordinate system of the input feature.
-
Line features are the only valid input.
-
When you select Use Page Unit and Scale Map, Map Scale becomes a required parameter. If ArcMap is open the map scale of the active data frame will be used; otherwise, the default value is 1. If you are specifying the size of index features in map space and Use Page Unit and Scale is not selected Map Scale is not needed.
-
Resulting index features are created with a number of attributes. These attributes include: PageNumber, GroupId, SeqId, PrevPage, NextPage, LeftPage, RightPage, TopPage, BottomPage and Angle.
- Angle is a numeric value expressing the rotation angle needed by the map (data frame) to align the edges of the index feature with the edges of a layout page. In order to keep within cartographic conventions, these angles are calculated to keep North oriented toward the top of the page as much as possible. Angles are calculated against the default orientation of a map where 0 degrees is due North, 90 degrees is due East, 180 degrees is due South and -90 degrees is due West.
- PageNumber is an incremental number assigned to each index feature.
- GroupId is an integer assigned to all the index features in a connecting chain or group of line features. Strip Map Index Features results can include multiple groups. Usually, a single group will originate from a connected set of line features or from a single line with multiple, unconnected parts. Index features created from Individual, unconnected line features will be assigned to separate groups. GroupId values are unique and are derived from the OID of the first line feature in the given chain.
- SeqId is an incremental number assigned to each index feature based on the creation order for the feature within each group.
- PrevPage is the PageNumber value for the previously created index feature. This field is used in analyzing the creation order of index features. Do not use this field to run dynamic text for a Data Driven Page. Use LeftPage, RightPage, TopPage and BottomPage fields for dynamic text.
- NextPage is the PageNumber value for the next index feature created. This field is used in analyzing the creation order of index features. Do not use this field to run dynamic text for a Data Driven Page. Use LeftPage, RightPage, TopPage, and BottomPage fields for dynamic text.
- LeftPage, RightPage, TopPage, and BottomPage are useful when incorporating the results into Data Driven Pages. LeftPage is the PageNumber value of the index feature that appears to the left of the current index feature after the rotation has been applied. RightPage is the PageNmuber of the index feature to the right. TopPage and BottomPage are the values for the index features to the top and bottom, respectively.
-
When Use Page Unit and Scale is selected the units for Length Along the Line and Length Perpendicular to the Line automatically changes to the page units set in the active map document (if ArcMap is open) or to inches if you are using the tool outside of an ArcMap session. For best results these units should be specified in page units such as inches or centimeters. If Use Page Units and Scale is not selected, units should be specified in map units such as meters, feet, kilometers, miles, or decimal degrees.
Syntax
Parameter | Explanation | Data Type |
in_features |
Input polyline or polylines defining the path of the strip map index features. | Feature Layer |
out_feature_class |
Resulting feature class of polygon index features. The coordinate system of the ouput feature class is determined in this order.
| Feature Class |
use_page_unit (Optional) |
Indicates whether index feature size input is in page space. The default value is NO_USEPAGEUNIT.
| Boolean |
scale (Optional) |
Map scale must be specified if index feature lengths (along the line and perpendicular to the line) are to be calculated in page space. If ArcMap is open the default value will be the scale of the active data frame. If ArcMap is not open the default will be 1. | Long |
length_along_line (Optional) |
Length of the polygon index feature along the input line feature specifed in either map or page units. The default value is determined by the spatial reference of the input line feature or features. This value will be 1/100 of the input feature class extent along the X axis. | Linear unit |
length_perpendicular_to_line (Optional) |
Length of the polygon index feature perpendicular to the input line feature specifed in either map or page units. The default value is determined by the spatial reference of the input line feature or features. This value will be 1/2 the number used for the length along the line. | Linear unit |
page_orientation (Optional) |
Used to determine the orientation of the input line features on the layout page. The default is HORIZONTAL.
| String |
overlap_percentage (Optional) |
The approximate percentage of geographic overlap between an individual map page and its adjoining pages in the series. The default is 10. | Double |
starting_page_number (Optional) |
Each grid index feature is assigned a sequential page number starting with a specified starting page number. The default value is 1. | Long |
direction_type (Optional) |
Index features are created in a sequential order and require a starting point. Setting the direction type for the strip map provides a starting point. The default is WE_NS. This means that the starting point for the strip map is either at the western end of the line feature if the line feature's directional trend is West to East/East to West or, if the directional trend is North to South/South to North, the starting point would be the northern most point of the line feature. The direction type is also applied to secondary line features.
| String |
Code Sample
Creates strip map index features based on the input line features with index feature dimensions specified for a layout page.
import arcpy
from arcpy import env
arcpy.env.workspace = "C:\data\ProjectData.gdb"
arcpy.StripMapIndexFeatures_cartography ("lines", "indexFeatures",
USEPAGEUNIT, "500000",
"7 inches", "5 inches")
Creates strip map index features based on the input line features with index feature dimensions specified for a layout page.
# stripmapindexfeatures_example1.py
# Description: Creates a series of strip map index features based on inputed
# line features with index feature dimensions specified for a layout page.
# Author: ESRI
# Import system modules
import arcpy
from arcpy import env
# Set environment settings
arcpy.env.workspace = r"C:\data\ProjectData.gdb"
# Set local variables
inFeatures = "line"
outFeatureClass = "indexFeatures"
usePageUnit = "USEPAGEUNIT"
scale = "500000"
lenA = "7 Inches"
lenP = "5 Inches"
# Execute StripMapIndexFeatures
arcpy.StripMapIndexFeatures_cartography (inFeatures, outFeatureClass,
usePageUnit, scale, lenA, lenP)
Creates strip map index features based on the input line features with index feature dimensions specified in map units with an overlap of 0.
import arcpy
from arcpy import env
arcpy.env.workspace = "C:\data\ProjectData.gdb"
arcpy.StripMapIndexFeatures_cartography ("lines", "indexFeatures", "",
"", "10 kilometers", "5 kilometers")
Creates strip map index features based on the input line features with index feature dimensions specified in map units with an overlap of 0.
# stripmapindexfeatures_example2.py
# Description: Creates a series of strip map index features based on inputed
# line features with index feature dimensions specified in map units with an
# overlap set at 0.
# Author: ESRI
# Import system modules
import arcpy
from arcpy import env
# Set environment settings
arcpy.env.workspace = r"C:\data\ProjectData.gdb"
# Set local variables
inFeatures = "line"
outFeatureClass = "indexFeatures"
lenA = "10 Kilometers"
lenP = "5 Kilometers"
# Execute StripMapIndexFeatures
arcpy.StripMapIndexFeatures_cartography (inFeatures, outFeatureClass, "",
"", lenA, lenP)
Creates strip map index features based on the input line features with index feature dimensions specified for a layout page and the page orientation set as vertical.
import arcpy
from arcpy import env
arcpy.env.workspace = "C:\data\ProjectData.gdb"
arcpy.StripMapIndexFeatures_cartography ("lines", "indexFeatures",
USEPAGEUNIT, "500000", "5 inches",
"7 inches", VERTICAL)
Creates strip map index features based on the input line features with index feature dimensions specified for a layout page and the page orientation set as vertical.
# stripmapindexfeatures_example3.py
# Description: Creates a series of strip map index features based on inputed
# line features with index feature dimensions specified for a layout and
# the page orientation set as vertical.
# Author: ESRI
# Import system modules
import arcpy
from arcpy import env
# Set environment settings
arcpy.env.workspace = r"C:\data\ProjectData.gdb"
# Set local variables
inFeatures = "line"
outFeatureClass = "indexFeatures"
usePageUnit = "USEPAGEUNIT"
scale = "500000"
lenA = "7 Inches"
lenP = "5 Inches"
pageOrientation = "VERTICAL"
# Execute StripMapIndexFeatures
arcpy.StripMapIndexFeatures_cartography (inFeatures, outFeatureClass,
usePageUnit, scale, lenA, lenP,
pageOrientation)
Creates strip map index features based on the input line features with specifications for feature dimensions in map units, starting page number, and strip map direction.
import arcpy
from arcpy import env
arcpy.env.workspace = "C:\data\ProjectData.gdb"
arcpy.StripMapIndexFeatures_cartography ("lines", "indexFeatures", "", "",
"10 kilometers", "5 kilometers",
"", "", "5", "EW_SN")
Creates strip map index features based on the input line features with specifications for feature dimensions in map units, starting page number, and strip map direction.
# stripmapindexfeatures_example4.py
# Description: Creates a series of strip map index features based on inputed
# line features with index feature dimensions specified in map units, the
# starting page number is 5 and the strip map direction is
# East-West/South-North.
# Author: ESRI
# Import system modules
import arcpy
from arcpy import env
# Set environment settings
arcpy.env.workspace = r"C:\data\ProjectData.gdb"
# Set local variables
inFeatures = "line"
outFeatureClass = "indexFeatures"
lenA = "10 Kilometers"
lenP = "5 Kilometers"
startingPageNum = "5"
directionType = "EW_SN"
# Execute StripMapIndexFeatures
arcpy.StripMapIndexFeatures_cartography (inFeatures, outFeatureClass, "", "",
lenA, lenP, "", "", startingPageNum,
directionType)