Show Navigation | Hide Navigation
You are here:
Mapping and visualization > Working with layers

Adding x,y coordinate data as a layer

Release 9.3
Last modified October 5, 2010
E-mail This Topic Printable Version Give Us Feedback

Print all topics in : "Working with layers"


Related Topics

About adding x,y coordinate data as a layer

Note: This topic was updated for 9.3.1.

In addition to data sources, such as a shapefile, you can also add tabular data that contains geographic locations in the form of x,y coordinates to your map.

X,y coordinates describe discrete locations on the earth's surface such as the location of fire hydrants in a city or the points where soil samples were collected. You can easily collect x,y coordinate data using a global positioning system (GPS) device.

To add a table of x,y coordinates to your map, the table must contain two fields, one for the x-coordinate and one for the y-coordinate. The values in the fields may represent any coordinate system and units such as latitude and longitude or meters.

The fields must be numeric for them to be displayed. For example, if the coordinate value is stored in degrees, minutes, and seconds in a field (for example, -120 13 58), you'll need to convert the values to decimal degrees and store them in a numeric field. In addition, some characters in field names are not supported, for example, dashes (such as x-coord for the field name), spaces, and brackets. Before adding x,y data, you should edit the field names to remove these characters. For example, you can use the underscore character instead of the dash character in field names.

Once you have added the data to your map, it becomes an XY event layer and behaves like other point feature layers. For instance, you can decide whether you want to display it, symbolize it, set the visible scale, or display a subset of features that meet some criteria.


XY event layers and ObjectID fields

If the table on which an XY event layer is based does not have an ObjectID field, you won't be able to perform certain tasks on the layer. Delimited text files or tables from OLE DB connections are some examples of tables without ObjectID fields.
Without an ObjectID field, you will not be able to



If you want to be able to perform these tasks, you can export the x,y layer to a new feature class or convert a table of coordinates into a point feature class in ArcCatalog. Both of these procedures create a fully functional feature class with an ObjectID. In addition, you can use the Make Query Table geoprocessing tool, which allows you to make the table using an OLE DB connection and to specify a column to use for the ObjectID or dynamically add the ObjectID.

Learn more about ObjectID fields


Converting degrees/minutes/seconds to decimal degrees

To create a point layer from x,y coordinates, the coordinates need to be in decimal degrees. There are several ways to convert degree/minutes/seconds (DMS) data into decimal degrees.

To convert it manually, use the following formula:
Decimal Degrees = Degrees + ((Minutes / 60) + (Seconds / 3600))

For example, 75 59 32.483 W would be -75.9923564 in decimal degrees. DMS is often followed by the hemisphere labels of N, S, E, or W. When converting to decimal degrees, convert longitude values that are in the western hemisphere or latitude values that are in the southern hemisphere to negative decimal degree values.

You can also use an advanced expression in the Field Calculator or use programming to perform the conversion automatically. You can find several sample scripts on edn.esri.com.


How to add x,y coordinate data as a layer

Adding x,y coordinate data as a layer

  1. Click the Tools menu and click Add XY Data.
  2. Choose a table that contains x,y coordinate data. If the table is not on the map, click the Browse button to access it from disk.
  3. Click the X Field drop-down arrow and click the field containing x-coordinate values.
  4. Click the Y Field drop-down arrow and click the field containing y-coordinate values.
  5. Click Edit to define the coordinate system and units represented in the x and y fields.
  6. The x,y coordinates will be automatically transformed to match the coordinate system of the data frame.
  7. Click OK.

Tips

  • To add x,y data, your coordinates need to be in the projected units or decimal degrees.
  • Check the Warn me box if you want to know when the new x,y layer has limited functionality because it does not have an ObjectID field. Without an ObjectID field, you will not be able to make selections, perform relates, edit it, or symbolize it in certain ways. However, you can create a new feature class from this data and be able to perform those tasks.
  • To create a permanent dataset (which will have an ObjectID), export your x,y layer to a new feature class. Right-click the x,y layer in the table of contents, point to Data, and click Export Data. To learn more, see Exporting features.
  • You can also create a new feature class from the x,y data in ArcCatalog. See the task below for more information.


Exporting the x,y layer to a new feature class

    See Exporting features.


Creating a point feature class from x,y coordinates

  1. Right-click a table in the Catalog tree that has columns containing coordinates, point to Create Feature Class, and click From XY Table.
  2. Click the X Field drop-down arrow and click the name of the column that contains the x-coordinates.
  3. Click the Y Field drop-down arrow and click the name of the column that contains the y-coordinates.
  4. If appropriate, click the Z Field drop-down arrow and click the name of the column that contains the z-coordinates.
  5. Click Spatial Reference of Input Coordinates and define the coordinate system for the input values as necessary.
  6. Click the Browse button.
  7. Click the Save as type drop-down arrow and click the format in which to create the new point features.
  8. Navigate to the folder or geodatabase in which you want to store the new features.
  9. Type a name for the new data source.
  10. Click Save.
  11. Set any Advanced Geometry Options and ArcSDE configuration keywords as necessary.
  12. Click OK.
  13. A new point data source is created in the appropriate location.

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