{"id":172,"date":"2013-04-29T23:19:04","date_gmt":"2013-04-29T23:19:04","guid":{"rendered":"http:\/\/www.lincoln.ac.nz\/conversation\/gis\/?p=172"},"modified":"2023-05-07T04:20:40","modified_gmt":"2023-05-07T04:20:40","slug":"how-do-i-create-a-new-feature-classshapefile","status":"publish","type":"post","link":"https:\/\/blogs.lincoln.ac.nz\/gis\/how-do-i-create-a-new-feature-classshapefile\/","title":{"rendered":"How do I create a new feature class\/shapefile?"},"content":{"rendered":"<p><em>This post covers an essential skill &#8211; creating new feature classes and shapefiles. \u00a0We&#8217;ll cover how to create a blank layer and then how to digistise new features into that.\u00a0 (Updated April 2020 for Pro)<\/em><\/p>\n<p>Creating you own data layers is an important part of most analysis projects, so in this post I&#8217;ll cover some of the essential steps in creating new feature classes or shapefiles. \u00a0Maybe you want to add some points so you can do some <a title=\"Data with a View\" href=\"http:\/\/blogs.lincoln.ac.nz\/gis\/data-with-a-view-2\/\" target=\"_blank\" rel=\"noopener noreferrer\">viewshed analysis<\/a>, or you need to create a layer that you can use to <a title=\"How do I Clip Data?\" href=\"http:\/\/blogs.lincoln.ac.nz\/gis\/how-do-i-clip-data\/\" target=\"_blank\" rel=\"noopener noreferrer\" data-wplink-edit=\"true\">clip out some data<\/a>. \u00a0The process is pretty much the same for both so initially I&#8217;ll focus on feature classes and finish up with what&#8217;s different with shapefiles. \u00a0In the following example, I&#8217;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. \u00a0Here&#8217;s the image:<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/QIPhoto-1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-3019\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/QIPhoto-1.jpg\" alt=\"\" width=\"1627\" height=\"873\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/QIPhoto-1.jpg 1627w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/QIPhoto-1-300x161.jpg 300w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/QIPhoto-1-1024x549.jpg 1024w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/QIPhoto-1-768x412.jpg 768w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/QIPhoto-1-1536x824.jpg 1536w\" sizes=\"auto, (max-width: 1627px) 100vw, 1627px\" \/><\/a><\/p>\n<p>If you look closely you can see the tracks &#8211; later on I&#8217;ll be able to use these to create the new features. \u00a0Let&#8217;s assume I&#8217;ve got an existing geodatabase as part of a project and I want to add the walking tracks layer into that.\u00a0 Go to the Catalog pane and open up Databases to see the geodatabase.<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/CatalogPane.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-2511 alignleft\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/CatalogPane.jpg\" alt=\"\" width=\"271\" height=\"261\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/CatalogPane.jpg 477w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/CatalogPane-300x289.jpg 300w\" sizes=\"auto, (max-width: 271px) 100vw, 271px\" \/><\/a>We first need to create a new, empty feature class to hold the track features.<\/p>\n<p>Right-click on the geodatabase and choose\u00a0New &gt; Feature Class.<\/p>\n<p>(You can create new shapefiles by right-clicking on a folder connection under Folders and choose New &gt; Shapefile.)<\/p>\n<p>We&#8217;ll step through a few windows to create a blank feature class and then digitise in some new features. \u00a0To create the new feature class I&#8217;ve got to set a few parameters. \u00a0In the first\u00a0pane 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. \u00a0The most important part of this step is ensuring that you&#8217;ve set the feature type to line in this case:<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-2512\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane1.jpg\" alt=\"\" width=\"322\" height=\"496\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane1.jpg 478w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane1-195x300.jpg 195w\" sizes=\"auto, (max-width: 322px) 100vw, 322px\" \/><\/a><\/p>\n<p>The Geometric Properties can be left as the defaults.\u00a0 Click Next and we can add any attributes (this can always be done later).\u00a0 Below I&#8217;ve added a text field called TrackName and set the Length (number of characters) to 25:<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane2.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-2513\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane2.jpg\" alt=\"\" width=\"317\" height=\"487\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane2.jpg 481w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane2-195x300.jpg 195w\" sizes=\"auto, (max-width: 317px) 100vw, 317px\" \/><\/a><\/p>\n<p>Click Next and then we can set the coordinate system. \u00a0For the most part, there are two main coordinate systems that interest us: New Zealand Map Grid (NZMG) and New Zealand Transverse Mercator (NZTM). \u00a0NZTM\u00a0superseded NZMG and the vast majority of the data on J: are in TM so I will set it to that coordinate system.\u00a0 If it&#8217;s not already set, the path is Projected Coordinate Systems &gt; National Grids &gt; New Zealand &gt; NZGD 2000 New Zealand Transverse Mercator.<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane3.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-2514\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane3.jpg\" alt=\"\" width=\"359\" height=\"558\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane3.jpg 484w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Pane3-193x300.jpg 193w\" sizes=\"auto, (max-width: 359px) 100vw, 359px\" \/><\/a><\/p>\n<p>(Note that you can add this to a Favorites folder to make it easier to find next time.) \u00a0Accept the defaults in the next three windows and click Finish to create a new blank layer. \u00a0You can now add this to a map so that the walking tracks can be digitised.<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/OnTheMap.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2515\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/OnTheMap.jpg\" alt=\"\" width=\"1920\" height=\"798\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/OnTheMap.jpg 1920w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/OnTheMap-300x125.jpg 300w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/OnTheMap-1024x426.jpg 1024w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/OnTheMap-768x319.jpg 768w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/OnTheMap-1536x638.jpg 1536w\" sizes=\"auto, (max-width: 1920px) 100vw, 1920px\" \/><\/a><\/p>\n<p>At this point, the new feature class is on the map but it&#8217;s empty.\u00a0 Are next step is to add some features.<\/p>\n<p><strong>Creating new features &#8211; digitising<\/strong><\/p>\n<p>The process of creating the new features is called digitising.\u00a0 By default, any vector layers that you&#8217;ve got stored locally are editable (this is a change from the days of ArcMap).\u00a0 To start editing, click over to the Edit tab and check out what&#8217;s available:<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/EditTab.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2516\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/EditTab.jpg\" alt=\"\" width=\"1920\" height=\"184\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/EditTab.jpg 1920w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/EditTab-300x29.jpg 300w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/EditTab-1024x98.jpg 1024w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/EditTab-768x74.jpg 768w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/EditTab-1536x147.jpg 1536w\" sizes=\"auto, (max-width: 1920px) 100vw, 1920px\" \/><\/a><\/p>\n<p>The Create button is the one for us &#8211; click it and a new pane opens at the right:<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/CreateFeaturesWindowPro.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-2517 alignleft\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/CreateFeaturesWindowPro.jpg\" alt=\"\" width=\"310\" height=\"219\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/CreateFeaturesWindowPro.jpg 483w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/CreateFeaturesWindowPro-300x212.jpg 300w\" sizes=\"auto, (max-width: 310px) 100vw, 310px\" \/><\/a><\/p>\n<p>It recognises my new layer and when I click the name I get a few different tools to work with.\u00a0 At the basic level of creating new features, the Line tool will work here (but do check out the other options).<\/p>\n<p>Click on this and note that the cursor changes to some crosshairs when over the map.<\/p>\n<p>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.<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Digisting1Pro.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2518\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Digisting1Pro.jpg\" alt=\"\" width=\"1026\" height=\"514\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Digisting1Pro.jpg 1026w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Digisting1Pro-300x150.jpg 300w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Digisting1Pro-1024x513.jpg 1024w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/Digisting1Pro-768x385.jpg 768w\" sizes=\"auto, (max-width: 1026px) 100vw, 1026px\" \/><\/a><\/p>\n<p>If I open up the attribute table, there&#8217;s now one record in there which is the feature I&#8217;ve just digitised (and since this is a feature class in a geodatabase we&#8217;ve automatically got a length field for that feature.)<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TablePro.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2519\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TablePro.jpg\" alt=\"\" width=\"1020\" height=\"259\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TablePro.jpg 1020w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TablePro-300x76.jpg 300w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TablePro-768x195.jpg 768w\" sizes=\"auto, (max-width: 1020px) 100vw, 1020px\" \/><\/a><\/p>\n<p>Since I&#8217;m still editing, I can click inside the TrackName cell for this record and type in a name.<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TrackName.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2520\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TrackName.jpg\" alt=\"\" width=\"1021\" height=\"679\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TrackName.jpg 1021w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TrackName-300x200.jpg 300w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TrackName-768x511.jpg 768w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/TrackName-330x220.jpg 330w\" sizes=\"auto, (max-width: 1021px) 100vw, 1021px\" \/><\/a><\/p>\n<p>Now I can go back to the map and add more track segments or edit the feature I&#8217;ve already digitised. \u00a0Since I&#8217;ve got some text for labelling I can display that also:<\/p>\n<p><a href=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/LabelledTrackPro.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2521\" src=\"https:\/\/d-blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/LabelledTrackPro.jpg\" alt=\"\" width=\"1504\" height=\"682\" srcset=\"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/LabelledTrackPro.jpg 1504w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/LabelledTrackPro-300x136.jpg 300w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/LabelledTrackPro-1024x464.jpg 1024w, https:\/\/blogs.lincoln.ac.nz\/gis\/wp-content\/uploads\/sites\/3\/2013\/04\/LabelledTrackPro-768x348.jpg 768w\" sizes=\"auto, (max-width: 1504px) 100vw, 1504px\" \/><\/a><\/p>\n<p>Creating points and polygons is quite similar, though some of the options with polygons get a bit complicated; something I&#8217;ll have to cover in another post.<\/p>\n<p>In this post we&#8217;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.) \u00a0The raster model is a very different story when it comes to creating new layers; another post as well.<\/p>\n<p>C<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This post covers an essential skill &#8211; creating new feature classes and shapefiles. \u00a0We&#8217;ll cover how to create a blank layer and then how to digistise new features into that.\u00a0 (Updated April 2020 for Pro) Creating you own data layers is an important part of most analysis projects, so in this post I&#8217;ll cover some [&hellip;]<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"class_list":["post-172","post","type-post","status-publish","format-standard","hentry","category-common-how-to-questions"],"_links":{"self":[{"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/posts\/172","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/comments?post=172"}],"version-history":[{"count":2,"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/posts\/172\/revisions"}],"predecessor-version":[{"id":4167,"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/posts\/172\/revisions\/4167"}],"wp:attachment":[{"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/media?parent=172"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/categories?post=172"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.lincoln.ac.nz\/gis\/wp-json\/wp\/v2\/tags?post=172"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}