Tag Info

New answers tagged

2

Electoral Districts Boundaries Census Data Data Archive - lots here


0

well the winner is to not use the = sign. this works for anyone looking.. ogr2ogr -overwrite -t_srs EPSG:3978 -f "ESRI Shapefile" -dialect SQLite -where "GIVEN_CLASS LIKE 'CLAS% A" dst src indicating dialect + using -where + Like operator.


-1

To answer this question nowadays (since ArcGIS 10.1 SP1) I would recommend the answer from @djq in conjunction with using arcpy.da.Walk to walk the folder structure: Generate data names in a directory/database structure by walking the tree top-down or bottom-up. Each directory/workspace yields a tuple of three: directory path, directory names, and ...


0

It seems that the shapefiles are locked. In ArcGis 10.x if a shapefile is opened (in ArcMap or ArcCatalog..), ArcGis automatically creates a file with the same name and pcname.numbers.sr.lock This prevent data as shapefiles to be edited if opened in multiple mxds or ArcCatalog in example. Try to open a new and empty mxd then run the merge between the two, ...


0

The datameet group has released a set of shapefiles, which includes the state of Telengana as separate from Andhra Pradesh: http://github.com/datameet/maps/ The data is shared under Creative Commons Attribution-ShareAlike 2.5 India license.


0

The Leica Zeno 20 with Zeno Mobile software is exactly what you are looking for. They have Hexagon Imagery Program (30cm resolution imagery) and Open Street Maps on each device as well as shapefile, ASCII and KML file export.


1

If you need to join csv to geometry file like shapefile (with attributes) in 1:N connection there is no simple way to do it as far as I am aware at this moment. One of the ways which I'm not going to describe in detail here is to import your csv as table into database together with your geometry features where you can do SQL queries and sure 1:N connections. ...


1

The problem is that your geometries have to match in terms of reference (the Spatial Reference System, which is identified by a number, the SRID). So if you want to look up a point in degrees (longitude, latitude), but the data is in a UTM zone, you need to use a transformation to get from something referenced to SRID of 4326 to SRID of 26914. In your ...


0

My issue relates to differing coordinate systems. My source data (the shapefiles) is using SRID 26914. Most GPS coordinates are using SRID 4326. I used this service to convert my GPS points into SRID points and with this query: select * from zones where within(GeomFromText('POINT(611646.08 3365787.37)'),zones.Geometry); I got the results I expected. I ...


1

The ERROR: function addGeometrycolumn(unknown, unknown, unknown, unknown,unknown, integer) does not exist means that the postgis extension is not installed on your postgresql. Go here and install it.


1

You can do it with field calculator using Python parser: Create a copy of your file Open table, select shape field, switch to advanced mode type: def pMove(shp): pM=arcpy.Point() p=shp.firstPoint pM.X=p.X-500 pM.Y=p.Y-500 return pM in the box below type: pMove(!Shape!) This is good place to learn about field calculator ...


0

for more info check: Enabling PostGIS PostGIS is an optional extension that must be enabled in each database you want to use it in before you can use it. Installing the software is just the first step. DO NOT INSTALL it in the database called postgres. Connect to your database with psql or PgAdmin. Run the following SQL: -- Enable PostGIS (includes ...


4

Can you use GDAL? The first step would to be create an output merge.shp file, so file1 you would do: ogr2ogr -f ‘ESRI Shapefile’ merge.shp filename1.shp Then update that merge.shp file with the other files: ogr2ogr -f ‘ESRI Shapefile’ -update -append merge.shp filename2.shp -nln merge You would loop that last command for each of the files that are ...


5

How precise do you need to be? Does it have to be exactly 500.0m South + 500.0 m West, or can you eyeball it? If you can eyeball it, the easiest way is just to turn on Editor mode: Then select all your points and drag them towards the southwest roughly 500.0*sqrt(2)=707.1m. Alternatively if you want to move all points precisely 500.0m South and ...


1

We'va had similar issues. The reason was we had several persons editing the same shapefile on the server at the same time, which destroyed the file. Columns and rows were shifted in the .dbf. Try to avoid simultaneous access. ArcGIS sometimes doesn't handle shapefiles correctly if the ID column is missing or empty. You should check this.


2

GeoServer supports the WMS GetLegendGraphics request. See: http://docs.geoserver.org/latest/en/user/services/wms/get_legend_graphic/legendgraphic.html


1

Since I've been helping my (non-GIS user) brother with this lately: Essentially you have to join your data table to your shapefile, but since XLS aren't readable by QGIS, you can use CSV and accomplish the same thing. open your XLS and remove all formatting from the sheet, if any (ie. colours or lines or anything like that) ensure all the column names are ...


0

The "Without PoK" data is a shapefile that has been converted from an image. The shapefile extents are (0,0) and (1496,1497) which represent the cell/pixel sizes of the original image. If you have the original image, you could try georeferencing it directly to your other data. Otherwise, you could try using the Spatial Adjustment toolbar, again to ...


1

This sounds like a fun problem. I would consider: Read the land boundary shp file using one of these recipes: How to install Fiona to read Shapefile attributes with OSGeo4W?. It would probably be good to read it into a Shapely geometry. I like using ogr to read shapefiles: import ogr import shapely driver = ogr.GetDriverByName('ESRI Shapefile') ...


5

You don't want to export csv, you should Save as... the shapefile which you joined the csv to. If you export csv table (which was not loaded with points geometry), there won't be any geometry and thus no shapefile. So it should go like this: drag and drop shapefile and csv into QGIS Double click on shapefile in layers list, switch to joins tab join csv to ...


1

Short answer - No. MXDs don't actually contain data, they're just containers that point to data that is stored somewhere else (as a shapefile, or in a file or personal geodatabase, or maybe as a KML/GPX). There are various ways to display that data on a mobile device. If you're using ESRI products, ArcGIS Online is the most direct route. I would ...


1

Generally speaking, you need to find the distance from shape centroid to the most distant point on its boundary. That should be the radius of the circumscribed circle. It's rather easy to achieve with PostGIS, not sure about QGIS.


1

You can download a Canada shapefile from DIVA-GIS and selecting the Administrative areas as the subject. You will receive 4 shapefiles of differing levels: Can_adm0 Can_adm1 Can_adm2 Can_adm3 (this is probably the one you want) When loaded into QGIS, you will see Canada broken up into different districts (or wards, zones, etc.). You can run a query to ...


1

If anything becomes tedious and repetitive then it's time to get smarter with your processing. You can automate all that you described by using modelbuilder. You drag the tools you used in to modelbuilder, connect them together to create a work flow and then run the model. You'll invest a bit of time creating the model but then you can tweak a parameter and ...


2

There is no need to use ArcPy for this. You can use the Field Calculator with its Python parser and if/elif(x4) to return values of 1 to 5 to a field, perhaps called GROUP. You can then Dissolve on GROUP to get the five features that you desire.


1

I found the answer on the gdal-dev mailing list. In summary, there are some .csv-files needed by the S-57 (ENC) reader. These are by default put in the GDAL_HOME/data directory (at least in GDAL 2.0.0), so for using ogrinfo you first need to do SET S57_CSV=C:\gdal\install\dir\data, then everything (both ogrinfo and your own programs) should be able to read ...


0

Robbi I'm not able to download your sample data on this laptop, but I understand the gist. This problem lends itself to an elegant solution in a few lines of script. I assume the points are snapped exactly on line endpoints - if not, you may need to run the Snap tool on the points first because the XY locations have to be identical for it to work. This is ...


0

you can also consider Mappt www.mappt.com.au where you can load Shapefiles, JP2's and also KML and KMZ.


1

I wasn't able to locate an API method in QGIS to do it, but there is a GDAL function: GDALRasterizeGeometries (there are a couple of variants.) This method is used internally by gdal_rasterize.


0

bugmenot123 already mentioned it, but ogr2ogr can convert between shapefiles and kml. There's another post that covers how to convert between the two.


0

i believe an additional solution would be to create a topology for the two datasets with rules like polygons must not overlap or must not have dangles/slivers etc. Then run your topology tool bar and your returned results will show each and every place the topology is incorrect. You would then manually go in and merge the errors into a the correct shape.


1

As @StevenKay mentioned, quotes on the GeoJSON should be escaped with preceding backslash. pgsql2shp -f tiles.shp -h <host> -u <user> -P <pass> <database> "SELECT id, the_geom FROM <table> WHERE ST_GeomFromGeoJSON('{ \"type\": \"Polygon\", \"coordinates\": [ [ [ -92.472398018272358, 18.086381878379395 ], [ -92.472398018272358, ...


0

Take a look at the Integrate (Data Management) tool. Input your shape files, choose a good tolerance, and run the tool. Be aware that it modifies the input data, so perhaps create some copies of your files to work with. Good luck!


4

The solution that comes to mind is to use a join between your shapefile and the textfile. Its described on this tutorial. If the attributes values change often, you could use a database backend for your data. QGIS works especially well with PostgreSQL-Postgis databases.


0

A line with arrows can be made with the line symbology, depending on the software you want to use: How to indicate flow of a watershed feature? . A simple > text symbology can work too. For the curved lines, you have to create great circle lines on a custom aeqd projection. See great circles in QGIS and export in 3857 webmap for a workflow.


1

As you surmise you need to change the schema. As schema are immutable you need to copy the existing schema into a new one changing the name of the geometry attribute. You will need something like: public boolean writeFeatures( FeatureCollection<SimpleFeatureType, SimpleFeature> features) { if (shpDataStore == null) { throw new ...


3

I took a look at the source code for the shapefile and found this (line 507): elif typ == b('D'): if value.count(b('0')) == len(value): # QGIS NULL is all '0' chars value = None else: try: y, m, d = int(value[:4]), int(value[4:6]), int(value[6:8]) value = [y, m, d] ...


0

In gvSIG 2.2, the last version of gvSIG, you can export .shp to .kml You can download gvSIG 2.2 and its manual from here: http://www.gvsig.com/en/products/gvsig-desktop/downloads Best, Alvaro Anguix http://www.gvsig.com/en/community/mailing-lists


2

DataStore dataStore = ....; // ShapefileDataStore String t = dataStore.getTypeNames()[0]; SimpleFeatureSource featureSource = dataStore.getFeatureSource(t); SimpleFeatureType schema = featureSource.getSchema(); String geomType = schema.getGeometryDescriptor().getType().getBinding().getName(); System.out.println(geomType); It will out one of the following: ...


5

On the page you linked to (that describes the data you converted), it says: MassGIS also projected the data into the Massachusetts State Plane Mainland coordinate system. Consequently, values in the range that you are observing, are to be expected. I am assuming that you were expecting latitude and longitude values but this data has been projected.


0

data is available online just search for it Data for Ivory Coast


0

numerous datasets available online. Data for Indonesia


0

Also have a look at the OpenStreetMap based service by user wambacher: https://osm.wno-edv-service.de/boundaries/ try the tree menu on the left screen to choose boundaries to be exorted in different formats. Be aware: Pay attention to the free licence used by OSM, and due to massive bulk downloads in the past some big download queries need a login ...


3

Found it here just now: https://ordercitrasatelit.wordpress.com/2013/03/16/free-peta-batas-administrasi-desa-seluruh-indonesia/ It is pretty detailed. It has up to level 4 administrative boundaries. Also it has area properties such as province, regency, kecamatan, etc.


1

Changing feature class column names directly in SQL Server will often corrupt the feature class as SDE keeps track of column names behind the scenes. Change the column names back to to their original names in SQL Server.


1

To select multiple features in ArcGIS 10.1 you can open up the feature layer's attributes and choose select by attribute. This will allow you to filter the selection by using certain fields to mark the features to be deleted. Along with that you can invert selection if you are able to easily select all of the features that you want to keep and then switch it ...


1

Try changing the selection mode in ArcMap to Add To Current Selection. Then you can select multiple features. See the link here for a discussion: http://resources.arcgis.com/en/help/main/10.1/index.html#//00s50000000w000000


0

There is still no simple solution to this conversion issue. It has been asked here multiple times in the last several years: kml-in-qgis-with-additional-data preserving-attributes-during-kml2shp-conversion-in-arcgis-for-desktop convert-kml-to-shapefile-without-losing-attribute-data esri's explanation for their KmltoLayer conversion tool: "As the ...


0

[Try this][1]How to create a 3D shapefile from a raster? Use libraries as shapely or fiona (included in QGis python), extracted z value, you can add for example to attribute table.


3

There is no real difference other than the class of the returned object. The raster intersect function is a helper function that, for polygons, calls gIntersection from rgeos (not rgdal). I would recommend using raster's intersect functions because it will save you some steps in getting back to a SpatialPolygonsDataFrame object. One good way to explore these ...



Top 50 recent answers are included