How do I create a new feature class/shapefile?
This post covers an essential skill – creating new feature classes and shapefiles. We’ll cover how to create a blank layer and then how to digistise new features into that. (Updated April 2020 for Pro)
Creating you own data layers is an important part of most analysis projects, so in this post I’ll cover some of the essential steps in creating new feature classes or shapefiles. Maybe you want to add some points so you can do some viewshed analysis, or you need to create a layer that you can use to clip out some data. The process is pretty much the same for both so initially I’ll focus on feature classes and finish up with what’s different with shapefiles. In the following example, I’ve got an aerial photograph of Quail Island in Lyttelton Harbour and I want to create a new layer of walking tracks from what I can see on the image. Here’s the image:
If you look closely you can see the tracks – later on I’ll be able to use these to create the new features. Let’s assume I’ve got an existing geodatabase as part of a project and I want to add the walking tracks layer into that. Go to the Catalog pane and open up Databases to see the geodatabase.
We first need to create a new, empty feature class to hold the track features.
Right-click on the geodatabase and choose New > Feature Class.
(You can create new shapefiles by right-clicking on a folder connection under Folders and choose New > Shapefile.)
We’ll step through a few windows to create a blank feature class and then digitise in some new features. To create the new feature class I’ve got to set a few parameters. In the first pane you can set the layer name, an alias (this is what will get displayed when the layer is added to a map) and a feature type. The most important part of this step is ensuring that you’ve set the feature type to line in this case:
The Geometric Properties can be left as the defaults. Click Next and we can add any attributes (this can always be done later). Below I’ve added a text field called TrackName and set the Length (number of characters) to 25:
Click Next and then we can set the coordinate system. For the most part, there are two main coordinate systems that interest us: New Zealand Map Grid (NZMG) and New Zealand Transverse Mercator (NZTM). NZTM superseded NZMG and the vast majority of the data on J: are in TM so I will set it to that coordinate system. If it’s not already set, the path is Projected Coordinate Systems > National Grids > New Zealand > NZGD 2000 New Zealand Transverse Mercator.
(Note that you can add this to a Favorites folder to make it easier to find next time.) Accept the defaults in the next three windows and click Finish to create a new blank layer. You can now add this to a map so that the walking tracks can be digitised.
At this point, the new feature class is on the map but it’s empty. Are next step is to add some features.
Creating new features – digitising
The process of creating the new features is called digitising. By default, any vector layers that you’ve got stored locally are editable (this is a change from the days of ArcMap). To start editing, click over to the Edit tab and check out what’s available:
The Create button is the one for us – click it and a new pane opens at the right:
It recognises my new layer and when I click the name I get a few different tools to work with. At the basic level of creating new features, the Line tool will work here (but do check out the other options).
Click on this and note that the cursor changes to some crosshairs when over the map.
Back on the map, click once to start the feature, once for every vertex (direction change) and double-click on a feature to finish it off.
If I open up the attribute table, there’s now one record in there which is the feature I’ve just digitised (and since this is a feature class in a geodatabase we’ve automatically got a length field for that feature.)
Since I’m still editing, I can click inside the TrackName cell for this record and type in a name.
Now I can go back to the map and add more track segments or edit the feature I’ve already digitised. Since I’ve got some text for labelling I can display that also:
Creating points and polygons is quite similar, though some of the options with polygons get a bit complicated; something I’ll have to cover in another post.
In this post we’ve seen how to create a new, blank layer (either a feature class or a shapefile) and then how to digitise in new features (and attributes as well.) The raster model is a very different story when it comes to creating new layers; another post as well.
C