Questions tagged [features]

Use this tag when asking questions about a representation of a real-world objects on a map.

Filter by
Sorted by
Tagged with
37
votes
6answers
35k views

Difference between map layer and spatial dataset (e.g. feature class, shapefile)?

What is the difference between a feature class and a feature layer? To me they seem very similar in concept.
10
votes
4answers
15k views

Get all the points of a polyline

I have some polyline feature objects in python. Now I want to get all the points of polylines. For example, if a polyline has start point [0,0] end point [5,5]. Result: [1,1];[2,2];[3,3];[4,4];[5,5]...
10
votes
4answers
42k views

Cutting features to do opposite of clipping in ArcGIS Desktop? [duplicate]

What´s the easiest/smartest way of getting the opposite output of the clipping tool? I just need the area of feature A1 which is not covered by feature A2 in a new Layer/File. Now, I get the result ...
27
votes
2answers
17k views

Reading feature class in file geodatabase using R?

I have a feature contained in a geodatabase that is larger than 2GB as an exported shapefile. I need to run an extract function in R to attribute the polygons with data from a raster file. Exporting ...
11
votes
2answers
12k views

How to change the value of an attribute using QgsFeature in PyQGIS?

I would like to update one attribute of a feature. However, I don't know to update it using the feature object. I have to use data provider to update it. layers = QgsMapLayerRegistry.instance()....
5
votes
1answer
3k views

Apply symbol to each feature (Categorized symbol)

I want to apply unique symbol to each feature. i have used following code for doing that from qgis.core import * from PyQt4.QtGui import * # supply path to where is your qgis installed QgsApplication....
5
votes
2answers
1k views

How to sum up values of overlapping polygons in QGIS?

I have large single layers with many features overlapping. Simplified example with 50% transparency: Where the features overlap I want the attributes added together. I manually created the output ...
3
votes
1answer
3k views

How to “Merge Selected Features” with python?

I have been looking for the answer to this question for some time now, but can't seem to find it! My problem is straight forward: I have one layer It contains lots of features (only polygons), say ...
4
votes
2answers
2k views

Updating raster value to reflect total number of points within cell using Python?

I have to do a task in Python/ArcPy/GDAL/whatever because I'm trying to automate this process for a hundred or so different raster/shapefile combos. This is what I need to do: I have an empty ...
4
votes
2answers
4k views

fixing polygons with “ring not closed” errors

I have a shapefile with a single Polygon feature. This feature has a "ring not closed" geometry error (seen here in QGIS): I tried using buffering and the GRASS v.clean command as suggested in other ...
2
votes
2answers
430 views

“Phantom” features showing up in QGIS?

I am using QGIS 2.4 on Windows 8.1. I have a project in which I have been digitizing from OpenMaps. Last night I was doing some more digitizing, saved, and closed the program. When I opened it this ...
2
votes
3answers
956 views

Symbolizing multiple polygons as one by dropping internal boundaries?

Using ArcMap (ArcGIS 10.2 for Desktop), is there a way to symbolize two features within the same feature class as one feature without editing the feature and merging them? For example, if I have a ...
2
votes
1answer
3k views

QGIS identify features button issue

Is there anyway to get the Identify Features button in QGIS to automatically select a layer and provide the information without having to highlight it first in the layers TOC? MapInfo and ArcGIS ...
4
votes
2answers
2k views

IdentifyFeature() use via PyQGIS?

Intent is to have two variables (QgsVectorLayer and feature.id() within said layer) as input for the Identify feature map tool in Qgis (2.6). Wondering if a feature can be selected programmatically (...
4
votes
1answer
734 views

Getting features in order they are selected using PyQGIS?

Is there a way of establishing the order that a user selected features using QGIS and Python? By example: we have a network of line features representing a road network, and the user defines a route ...
3
votes
2answers
3k views

Delete SDE feature class features with ArcPy

I'm working on a script that will empty my SDE database of all data. How would I go about deleting features from feature classes using ArcPy? I have an SDE connection created with a user that should ...
2
votes
1answer
649 views

Cutting rectangle set (not squares) into triangles using ArcGIS for Desktop?

I have some large features that I need to split into smaller pieces for terrain alignment through vertices in another program. I figured triangles would be the best solution. So basically I want to ...
2
votes
2answers
5k views

Defining which layer (overlay) is displayed on Leaflet map?

I have 7 layers overlay on a base map, i need to define which layer is selected (active,displayed,shown) on the map. var overlays = { "AL HOUDA Espaces_Verts": alhouda6_layer, "...
6
votes
1answer
18k views

OpenLayers: Get Coordinates of drawn features

Can someone help in finding coordinates of drawn features? I am using this example OpenLayers website. I need to be able to export drawn objects as set of coordinates. Posting the code from the ...
5
votes
2answers
264 views

QGIS renders outlines where none should be

QGIS always renders the borders of a feature polygon. How can I disable this? Even if I set Border style to "No Pen" and the colour is exactly the same for different categories there is a small grey ...
1
vote
2answers
733 views

Length of Feature

I have a shapefile which renders a map. I want to calculate and preferably store length of each feature in the shapefile either using QGis or through programmatic means. What is the best way to get ...
0
votes
1answer
2k views

Merge two points of two different polygons to get one polygon at the end

I would like to join points from two different features. I already searched for plugins, but so far but didn't find one working plugin or solution for my task. So here is a picture of 2 polygons/...
7
votes
5answers
6k views

Using OpenLayers Selectfeature get mouse position? [closed]

How do I get mouse coordinates after a SelectFeature, which returns the feature by itself?
11
votes
2answers
8k views

How to use label classes, expressions, and annotations?

I've always found that when it comes to python, vector analysis, QGIS gives ArcGIS a run for its money, hell some of the qgis plugins exceed ArcGIS's performance by a few hours; however, I always have ...
8
votes
2answers
19k views

Displaying properties of GeoJSON in popup on Leaflet?

This is my simple GeoJSON with Leaflet map. I want to display properties as popup but I don't know why it is empty. Can you tell me my mistake? <html> <head> <title>A Leaflet map!...
13
votes
2answers
11k views

Difference between Copy Features and Feature Class to Feature Class tools?

I have a feature class within a feature dataset in a file geodatabase (FGDB), and I need a copy of it in another FGDB. In ArcGIS 10.1, I've used the "Copy Features" tool, and it looks to be the same (...
10
votes
1answer
824 views

Features in commercial GIS software missing in FOSS GIS?

For example, a program I use (TransCAD) has the ability to do travel time matrices based on minimal data input, which is really useful if you're looking at doing back of the envelope type calculations....
9
votes
1answer
4k views

How to Verify if a FeatureLayer already exists?

I am currently working on a project where when user loads up their map (mxd) into our system, we create several custom featuerlayers for them. My problem is though, I have no idea how to check if I ...
12
votes
3answers
20k views

Exporting multiple featureclasses to shapefiles using ArcGIS Desktop?

I have many feature classes in a geodatabase and I need to save/export them into shapefiles. Any Ideas? Click on every single layer -> export is not a good option, due to the number of feature ...
11
votes
3answers
6k views

What is a non-geographical feature?

When using the term "feature" in GIS, what is often (if not always) meant is a geographical feature which "is a representation of real world phenomenon associated with a location relative to the Earth"...
8
votes
2answers
5k views

QGIS select feature, “add to current selection” feature

I am trying to perform a feature selection on qgis similar to "add to current selection" interactive selection method in Arcgis Desktop, is that possible? An example: I perform a spatial query and ...
6
votes
2answers
815 views

What does feature mean in QGIS?

I can't understand the meaning of feature in QGIS QgsFeature class. How it is related to layer and geometry? I have read QGIS documentation but I can't understand what is feature.
4
votes
1answer
394 views

GetFeatureCount gives same result after deleting a feature

This is my code: num1 = layer.GetFeatureCount() layer.DeleteFeature(1) layer.SyncToDisk() num2 = layer.GetFeatureCount() print num1 print num2 For some reason, num1 and num2 are the same number. Why?...
3
votes
3answers
1k views

How can I turn islands into individual features in QGIS?

I have what seems like a pretty straightforward task in QGIS: I have a shapefile that, in some cases, groups multiple separate landmasses into a single feature. For example, the Hawaiian islands are ...
7
votes
2answers
259 views

Features to stay selected by default in QGIS?

Does anyone know if there's a way to configure QGIS so that when you plot a new feature (i.e. a polygon), it stays selected by default? If I have to select it separately, and it happens to fall on ...
6
votes
2answers
6k views

Merging overlapping line segments in ArcGIS Desktop?

I'm working with fish distribution data, and have combined several 24k habitat maps into a single layer that I'll call "critical habitat" In merging multiple distributions into one dataset, there are ...
6
votes
1answer
227 views

How to store and serve data and its progress over time in GeoServer?

I recently started working with GeoServer and stored some shapefiles. I successfully can retrieve the data as JSON. The data I want to maintain in the database changes over time. I do not want to ...
5
votes
3answers
810 views

Selecting polygons by number of sides

I'm using ArcGIS 10 to build some figures for a journal article. One is a figure of an unstructured finite element mesh of triangles spanning the western Atlantic Ocean. I exported this mesh from ...
4
votes
1answer
2k views

How to integrate OpenLayers and ArcGIS Server?

I am using the OpenLayers JavaScript API within a web application. I am displaying non-base layers hosted on an ArcGIS server. When I load the ArcGIS layers, I load them using OpenLayers.Layer....
4
votes
2answers
2k views

Replicating ArcMap's Point Sketch Geometry Editing (Feature Templates) in ArcObjects

I'm looking for a way to place, select, move, delete features inside a custom C# ArcObjects application (using AxMapControl). I found the exact behavior in ArcMap, but I want to save the user some ...
4
votes
1answer
2k views

How to create and remove multiple QgsRubberBands in PyQGIS?

Currently the following code-snip works great to highlight a shape based on the 'feature' and 'layer' variables: self.rubberHighlight = QgsRubberBand(self.iface.mapCanvas(),QGis.Polygon) self....
3
votes
1answer
461 views

Is it possible to change the geometry without startEditing the layer

I am working in c++/QT 4.5 with the QGis 2.8.2 API. I had to change the geometry of features in a layer each second. Each second new data comes from the Ethernet connection, the application gets the ...
3
votes
3answers
14k views

How to select features of visible layers in QGIS

In QGIS 1.8 I used plugin "Select features of visible layers by rectangle" to know the layer that owns a visible feature. In QGIS 2.0.1 this plugin is no more available. I wonder if it is possible to ...
2
votes
2answers
9k views

In QGIS combine multiple polygon parts of a single feature

This is a repost of my unsolved QGIS dilema. The image shows a single selected feature that consists of two polygons and the corresponding attribute table. Some nodes of the left poly have been added ...
2
votes
3answers
2k views

how to change color of feature to mark it as recently modified with openlayers

I am developing a crowd sourced app using openlayers. after user clicks an feature, a popup form is displayed. After clicking the save button, the data is used in processing which takes some time so ...
1
vote
1answer
1k views

How to iterate through each vertex in a line?

I am working with ArcObjects in building functionality for a toolbar inside of ArcMap. Once I start an edit session, I use the tools to manually draw a line. I am trying to loop through this line get (...
1
vote
2answers
4k views

Selecting features based on another feature attributes?

Here is my case: I have a layer of features (buildings from a city) that is populated with polygons. This polygons have attributes : street name and postal code In the project I have another layer of ...
1
vote
1answer
596 views

Why new feature disappears when editing polygon?

I try to create internal polygon within existing polygon. After I created a ring, I add a new feature inside the ring. Suddenly, this new feature disappears. I confirmed that this feature went to the ...
9
votes
2answers
11k views

How can I unselect a feature in Openlayers?

I am able to identify the selected features on my map using the following line: vector_layer.selectedFeatures I would like to be able to deselect this feature using a standalone function (not an ...
6
votes
3answers
2k views

Mapping a feature from the attribute table in QGIS?

I currently finished adding all the needed attributes for my research. I would like to map these attributes. Is there any way to do so? The original method I was taught was to select: on the map and ...