Questions tagged [shapefile]

A vector data storage format for storing the location, shape, and attributes of geographic features. Often referred to as 'an ESRI shapefile', as ESRI developed it.

Filter by
Sorted by
Tagged with
1
vote
0answers
21 views

Can we include any URL path for the Shapefile while creating a feature store in Deegree GIS?

I have used the Documentation and the examples of Deegree GIS application and I am able to give the path for my Shapefile in my local system, while creating a feature store just like below. <...
1
vote
1answer
42 views

Merging attributes into shapefile (US County-level data) using R

I'd like to make a plot of the US, with each county colored according to a scalar value (the average summer temperature). I'm using R. I have a shapefile with all the counties: > shape = st_read(...
2
votes
2answers
96 views

Finding the average of a raster across a given region, in R, for many points in time

I have a time-series of rasters (daily maps of global temperature for the past year), and a shape-file outlining state boundaries. I'd like to find the average temperature in each state on each day of ...
1
vote
1answer
42 views

I cannot manage to export coordinates to a shapefile using Python

This is the test code I have written: import shapefile w = shapefile.Writer(shapefile.POLYGON) w.poly(parts=[[[1,5],[5,5],[5,1],[3,3],[1,1]]]) w.field('FIRST_FLD','C','40') w.field('SECOND_FLD','C','...
0
votes
1answer
37 views

Rasterizing shapefile with attribute value as pixel value labels with GDAL in Python

I am new to GDAL and geom shapefiles. I have a 3-band .img file (with other associated files) as raster images. And also a shapefile which includes 10000+ features (multi-polygons), the properties of ...
1
vote
1answer
48 views

Shapefile points, individual editing

I am very new to QGIS and have run into a problem dealing with shapefiles. Recently, I went into the field with an app for smartphones called 'SW Maps' that I used to create some basic layers for ...
1
vote
1answer
37 views

Calculate ratio of a vector field within a raster grid cell

I have a large dataset (shapefile) in which one variable is binary. I want to be able to find the fraction of 1 for all the points, but within a given raster grid cell, see below. Yes, as you can see ...
1
vote
1answer
91 views

Making a for loop/function testing geometries' intersections for multiple time-units in R

I have two multipolygons and I want to test intersections between their geometries based for different cycles of years. Basically I have a flood dataset that contains flood events and their geometry ...
1
vote
1answer
108 views

How to execute GDALRasterize() function wtih options?

I am using GDAL 2.1.0, in both Windows and Linux environments. I want to programmatically rasterize a shape file in my C++ app. Thanks for any clues you can provide. gdal_rasterize I can successfully ...
0
votes
0answers
35 views

importing shapefiles into AutoCAD map

I need to import a complex polygon shape file into AutoCAD (AutoCAD map 3D 2015). I can import using Mapimport command, I can use the shp attributes to split into different drawing layers etc. What I ...
1
vote
1answer
81 views

Extracting shapes from GeoTIFF using rasterio returns excessive number of polygons

I am using the shapes interface of rasterio to extract polygons from a GeoTIFF image. rasterio returns an excessive number of polygons which is not expected. It is taking a long time to extract a ...
-1
votes
1answer
21 views

Should a GDAL vector dataset have a geotransform?

For example: Does a shapefile have a geotransform? The answer is probably: No, a vector dataset does not have a geotransform, because the purpose of a geotransform is to transform between projection ...
1
vote
1answer
43 views

Merging attributes by location in PostGIS

I am a newbie on PostGIS and I want to transfer an attribute or even a symbology from a layer to another. For example, I have a file with points that each country has a point at the center, I want to ...
0
votes
0answers
24 views

Naming and Extracting shapefiles using value from attribute table using ArcGIS Pro ModelBuilder

I am working with ModelBuilder in ArcGIS Pro to create a process that will select a distinct shapefile from a feature class and create a new layer. This new layer will then be used to clip and extract ...
3
votes
0answers
60 views

Plotting the albedo using Python

import glob import numpy as np import pandas import os import rasterio import geopandas as gpd import matplotlib.pyplot as plt def get_image_stats_only(img_array): raw_stats_dictionary = {'mean':...
1
vote
0answers
51 views

Measuring distance from centroid to polygon's boundaries in R

I'm still new to raster and sf and I'm having some trouble getting a distance between a point and a polygon for every time period. I have a sf object with MULTIPOLYGONS that refers to flood episodes ...
0
votes
2answers
78 views

Problem with spatial join of large shapefiles

I want to combine the attributes of five shapefiles into one shapefile using QGIS. Therefore, I used several data processing steps including clipping the five shapefiles to the boundaries of my ...
0
votes
0answers
30 views

SHP file of GDAM polygon of my country to my ASSETS not match the map base borders in GEE

I upload GDAM polygon of my country as shp file to my ASSETS but as layer this borders not match the map base of GEE. Other source Geofabrik OSM shp files are exactly the same as on GEE, but they are ...
1
vote
2answers
177 views

Import shapefile to SQL Server 2019 using OGR2OGR

I'm trying to import a shapefile into SQL Server 2019, running his command: ogr2ogr -progress -f "MSSQLSpatial" "MSSQL:server=XXXX;database=test;UID=XXXXX;PWD=XXXX" "MYFILE&...
0
votes
1answer
317 views

Convert Numpy array to shapefile

I read in a raster and turned it into a binary image (land/water mask) of 0's (water) and 255's (land). I've named this array src_landCoverArray. I want to output this array as a shapefile with water ...
0
votes
1answer
34 views

Keeping symbology properties when converting from CSV layer to shapefile in QGIS

Is it possible to keep specific symbology settings when converting from a CSV file to a shapefile in QGIS? I've added categorised renderer settings within my CSV file layer and don't want to loose ...
1
vote
1answer
55 views

How to split a single polyline shapefile into many shapefiles based on unique value using GeoPandas?

I have a single polyline shapefile with multiple features (row). I want to export each row to separate shapefile with using GeoPandas. But I got Geometry error in the code. This is my shapefile: and ...
0
votes
1answer
77 views

Converting shapefile to raster by passing specific column/variable using GDAL in Python

Followed the steps from this link to create raster from shapefile using GDAL Convert an OGR File to a Raster but it is returning an empty raster. Can someone tell how to define a particular column ...
2
votes
1answer
62 views

GeoPandas: Problem with encoding

I have the problem with encoding because I need Polish letters and encoding="utf-8" didn't work. import geopandas df = geopandas.read_file(r'/home/gis/adresypolska/PRG_PunktyAdresowe_POLSKA....
0
votes
1answer
55 views

Test intersections with time indicators in R

I have a sf object with MULTIPOLYGONS that refers to flood episodes from 1800's onwards(https://data.gov.uk/dataset/16e32c53-35a6-4d54-a111-ca09031eaaaf/recorded-flood-outlines). Then I have another ...
3
votes
1answer
59 views

Selecting points shapefile by raster values

I have a shapefile point (with 200 points record) and a raster image (with 5 classes). I want to select points that fall within a specific class of the raster image. For example, I want to select ...
0
votes
1answer
31 views

How can I import assets of type folder shared by my co-worker?

I am very new to Google Earth Engine. My coworker shared his asset folder with me but as i open the link it gives me an error that "Unable to import asset of type folder".
1
vote
2answers
91 views

Converting a shapefile from decimal degrees to UTM (km) in R

The code that I have below seems like it works in converting my vector roads which is in decimal degrees into a UTM CRS so that I can more easily work on the data in kilometers rather than decimal ...
2
votes
0answers
26 views

Using ogr2ogr to convert Natural Earth data to Polar Stereographic projection

I’m trying to build some maps of the North Pole area for my website. I’ve flown over it a few times and want to make a map of the flight paths I took. As you can see, a normal Mapbox map doesn't look ...
4
votes
1answer
106 views

Changing field values on a attribute table using GDAL/OGR (ESRI Shapefile)?

I am trying to create a new column on attribute table of my shapefile. This table must be the FID formatted with 4 (or any number) digits (for instance: 0 = 0000, 1 = 0001, 2 = 0002...) but I just can'...
1
vote
0answers
46 views

Wrong scale in Print layout mode

I´m using qgis 3.16 and have the folowing Problem: If i´m in the primary Window the scale on the bottom of the scrren shows me a correct value, but if i switch into the Printlayout mode the value of ...
0
votes
1answer
87 views

Converting a Road shp file into a continous Road Raster in QGIS?

I have converted a Road shp file into a Raster in QGIS, however after the conversion the Road is no longer continous (i.e only the cell corners are touching). I have tried increasing the resolution ...
1
vote
1answer
33 views

Merging two shapefiles only for those polygons that have same boundaries or within tolerance distance using ArcMap

I have two shapefiles for district boundaries of India in 2001 and 2020. Because boundary of districts changed over time since districts merge and split, I want to export only those districts (they ...
4
votes
2answers
234 views

Combining CSV and shapefile to find area name where stations are located

I have one shapefile with marine areas. The other is a CSV file with some station names and coordinates. I would like to get table with stations names and corresponding marine area names, where the ...
0
votes
0answers
17 views

Summing values of smaller polygons within larger ones using ArcMap

I am trying to find the population for Neighborhoods in Chicago. I have a shapefile of the Neighborhoods and a shapefile of census tracts with the population for each tract. The neighborhoods are ...
2
votes
1answer
47 views

Create a raster from polygon

I have a shapefile of thousands of polygons. I'm looking to loop through each polygon and create a raster of the shapefiles boundaries for each polygon. I'm looking for each raster to have the value ...
1
vote
1answer
35 views

Different styles of area in same shape layer

I'm using QGIS 3.16. I have the following problems: One of my shape-layer has several areas. Now I want to give every area a different style/colour. I already found the function to give all areas the ...
0
votes
1answer
84 views

Merging shapefile with dataframe and plotting using R

I am using R. I have a shapefile that gives me the provincial boundaries for a state and I want to use another dataset to combine the aggregate total enrolment in schools by 'district' to the ...
2
votes
1answer
51 views

Lost Polygons after clipping Shapefile using QGIS clip fuction

I'm trying to clip the CORINE Land Cover 10 ha Shapefile (https://gdz.bkg.bund.de/index.php/default/open-data/corine-land-cover-10-ha-clc10.html) with a district shapefile to get my investigation area....
0
votes
0answers
29 views

Editing areas in shapefile + scalebar

I´m using Qgis Version 3.16 I have the following problems: One of my layer has several areas. Now I want to give every area a different style. I already found the function to give all areas the same ...
0
votes
1answer
90 views

QPJ Files missing [closed]

So i have these shapefiles which i got for a thesis, a shapefile layer with 6 files. And i tried to make a shapefile layer where i crop the district from the old layer and pasted it in the new layer. ...
1
vote
1answer
40 views

PyQGIS CRS projection issue when converting shapefile to heatmap

I am trying to create a Python script that runs in the QGIS Python Console and uses the QGS API to create KDE heatmaps from shapefiles. The shapefiles can come in any number of CRS's but the heatmaps ...
0
votes
1answer
26 views

Extracting a region's outline of roads from a GIS database, as a vector image

It's now about 5 days I've been trying to extract an outline of the internal transportation routes of a city (Tehran) from various kinds of GIS sources, and exporting that outline as a vector image, ...
1
vote
1answer
65 views

How to override shapefile geometry type in OGR

I'm new to ogr. I tried to copy a WFS layer to shapefile using CopyLayer but I get this error. ERROR 6: Geometry type of `Multi Curve' not supported in shapefiles. Type can be overridden with a layer ...
0
votes
1answer
56 views

OGR - 'NoneType' object has no attribute 'CreateLayer'

I have an error when i wan't to create a Shapefile layer with OGR. When I run my script for the first time, everything all right, layer is well created. But when i run it for the second time ...
0
votes
0answers
21 views

Creating shapefile using GDAL OGR? Script runs but does not create the files

This script runs but does not create the shapefile files. It works, however, if I were to replace the driver for GeoJSON and create a GeoJSON file. Context: I'm working through Chris Garrard's "...
0
votes
0answers
29 views

Two files with same coordinate systems should overlap but don't [duplicate]

I'm a complete beginner and I have been trying to solve this problem for hours now without success. I know there are other questions like this one and I've tried to apply the answers to my problem, ...
1
vote
0answers
65 views

No transform is available between OGC:CRS84 - WGS 84 (CRS84) and EPSG:3035 - ETRS89-extended / LAEA Europe

I am trying to add a shapefile to QGIS that contains reconstructed UK postcode polygons (January 2015), which can be found in this link https://www.opendoorlogistics.com/downloads/ in the section 'UK ...
1
vote
1answer
231 views

Creating polygons from points with undefined order using QGIS

I have a point shapefile that contain a batch of features. I want to create polygons from these points. Each point should define a boundary of polygon. There is an unique "ID" field that ...
4
votes
1answer
388 views

Reading non-standard JSON / TopoJSON files in GeoPandas

I am unable to read a TopoJSON / JSON file in GeoPandas. The issue is that it's a JSON file with keys that are "probably" not standard. I tried to use the from_features() method but it gives ...

1 2 3
4
5
97