Smooth Line (Data Management) (ArcInfo and ArcEditor only) |
|
Release 9.2
Last modified November 29, 2010 |
![]() ![]() ![]() Print all topics in : "Tools" |
Smoothes a line to improve its aesthetic or cartographic quality.
Learn more about how Smooth Line works
Illustration
Usage tips
The Polynomial Approximation with Exponential Kernel (PAEK) algorithm produces smoothed lines; each may have more vertices than its source line. The tolerance you specify is the length of a "moving" path used in calculating the new vertices. The longer the length, the more smoothed the line. A small tolerance will result in a long processing time, so begin with a relatively large tolerance and a small number of lines.
The BEZIER_INTERPOLATION algorithm does not require any tolerance. If you are using the command line or scripting, you still need to enter zero in place of the smooth_tolerance.
When BEZIER_INTERPOLATION is used for shapefile output, it will produce lines very close to Bezier curves, since a shapefile cannot store true Bezier curves.
Both algorithms may introduce topological errors, such as line crossings, in the results. If you are not concerned about the topological errors, use the default, NO_CHECK option. If you want to know about the errors, use the FLAG_ERRORS option so that If any are found, a new field, SmoLnFlag, will be added to the output, storing a value of 1 for lines with topological errors and a value of zero to others.
The following environment settings affect this tool: XY tolerance, Extent, M domain, Coordinate system, Output has M values, Output has Z values, Default Z value, Output XY domain, workspace, and scratch workspace.
Command line syntax
An overview of the Command Line window
SmoothLine_management <in_features> <out_feature_class> <PAEK | BEZIER_INTERPOLATION> <tolerance> {FIXED_CLOSED_ENDPOINT | NO_FIXED} {NO_CHECK | FLAG_ERRORS}
Parameter | Explanation | Data Type |
<in_features> |
The line features to be smoothed. |
Feature Layer |
<out_feature_class> |
The output feature class to be created. |
Feature Class |
<PAEK | BEZIER_INTERPOLATION> |
Specifies the line smoothing algorithm.
|
String |
<tolerance> |
Sets a tolerance used by the PAEK algorithm. A tolerance must be specified, and it must be greater than zero. You can specify a preferred unit; the default is the feature unit. |
Linear unit |
{FIXED_CLOSED_ENDPOINT | NO_FIXED} |
Specifies whether to preserve the endpoints for closed lines. This option works with the PAEK algorithm only.
|
Boolean |
{NO_CHECK | FLAG_ERRORS} |
Specifies how the topological errors (possibly introduced in the process, such as line crossing) will be handled.
|
String |
smoothline contours smoothed_contours BEZIER_INTERPOLATION 0.0
Scripting syntax
About getting started with writing geoprocessing scripts
SmoothLine_management (in_features, out_feature_class, algorithm, tolerance, endpoint_option, error_option)
Parameter | Explanation | Data Type |
in_features (Required) |
The line features to be smoothed. |
Feature Layer |
out_feature_class (Required) |
The output feature class to be created. |
Feature Class |
algorithm (Required) |
Specifies the line smoothing algorithm.
|
String |
tolerance (Required) |
Sets a tolerance used by the PAEK algorithm. A tolerance must be specified, and it must be greater than zero. You can specify a preferred unit; the default is the feature unit. |
Linear unit |
endpoint_option (Optional) |
Specifies whether to preserve the endpoints for closed lines. This option works with the PAEK algorithm only.
|
Boolean |
error_option (Optional) |
Specifies how the topological errors (possibly introduced in the process, such as line crossing) will be handled.
|
String |
# Simplifying rivers followed by smoothing rivers import arcgisscripting gp = arcgisscripting.create() # Set the workspace gp.workspace = "d:/data/mapDB.mdb/hydrography" # Simplifying rivers followed by smoothing rivers gp.simplifyline("rivers", "rivers_simplified", "BEND_SIMPLIFY", "80", "RESOLVE_ERRORS") gp.smoothline("rivers_simplified", "rivers_smoothed", "PAEK", "150")