Show Navigation | Hide Navigation
You are here:
Geoprocessing tool reference > Analysis toolbox > Proximity toolset > Tools

Near (Analysis) (ArcInfo only)

Release 9.2
Last modified January 13, 2009
E-mail This Topic Printable Version Give Us Feedback

Print all topics in : "Tools"


Related Topics

Determines the distance from each point in the Input Features to the nearest point or polyline in the Near Features, within the Search Radius.


Illustration

Near illustration

Usage tips

Command line syntax
An overview of the Command Line window
Near_analysis <in_features> <near_features> {search_radius} {NO_LOCATION | LOCATION} {NO_ANGLE | ANGLE}

Parameter Explanation Data Type
<in_features>

The feature class or layer containing points from which distances are calculated to each closest polyline or point in the Near Features.

Feature Layer
<near_features>

The feature class or layer containing points or polylines whose features are used to calculate distances from each point in the Input Features.

Feature Layer
{search_radius}

The maximum distance between Input Features and Near Features for which distance and FID will be determined.

Linear unit
{NO_LOCATION | LOCATION}

Determines whether the x,y coordinates of the nearest feature are added to the Input Features, as well as NEAR_FID and NEAR_DIST. The new fields are NEAR_X and NEAR_Y.

  • NO_LOCATION — The x,y coordinates or the nearest point are not saved. This is the default.
  • LOCATION — The x,y coordinates of the nearest point, NEAR_FID, and NEAR_DIST will be saved.

Boolean
{NO_ANGLE | ANGLE}

Determines whether the angle between the near feature will be saved, as well as NEAR_FID and NEAR_DIST.

  • NO_ANGLE — The angle between the nearest point will not be saved. This is the default.
  • ANGLE — The angle between the nearest point will be saved.

Boolean
Data types for geoprocessing tool parameters


Command line example

Near_analysis D:\Workspace\wells.shp D:\Workspace\seis.shp 25000 LOCATION ANGLE

Scripting syntax
About getting started with writing geoprocessing scripts
Near_analysis (in_features, near_features, search_radius, location, angle)

Parameter Explanation Data Type
in_features (Required)

The feature class or layer containing points from which distances are calculated to each closest polyline or point in the Near Features.

Feature Layer
near_features (Required)

The feature class or layer containing points or polylines whose features are used to calculate distances from each point in the Input Features.

Feature Layer
search_radius (Optional)

The maximum distance between Input Features and Near Features for which distance and FID will be determined.

Linear unit
location (Optional)

Determines whether the x,y coordinates of the nearest feature are added to the Input Features, as well as NEAR_FID and NEAR_DIST. The new fields are NEAR_X and NEAR_Y.

  • NO_LOCATION — The x,y coordinates or the nearest point are not saved. This is the default.
  • LOCATION — The x,y coordinates of the nearest point, NEAR_FID, and NEAR_DIST will be saved.

Boolean
angle (Optional)

Determines whether the angle between the near feature will be saved, as well as NEAR_FID and NEAR_DIST.

  • NO_ANGLE — The angle between the nearest point will not be saved. This is the default.
  • ANGLE — The angle between the nearest point will be saved.

Boolean

Data types for geoprocessing tool parameters


Script example

import arcgisscripting
gp = arcgisscripting.create()

gp.workspace = "D:/Workspace"
gp.toolbox = "analysis"
gp.near("wells.shp", "seismic.shp", "25000", "LOCATION", "ANGLE")

Please visit the Feedback page to comment or give suggestions on ArcGIS Desktop Help.
Copyright © Environmental Systems Research Institute, Inc.