Tag Info

Hot answers tagged

19

Vector data can have properties stored at two levels. File level or Layer level. For feature class (a type of vector data), file level information is stored in a geodatabase. This consists of properties like feature class geometry, attribute table, assigned subtypes and domains, a coordinate system, etc:. All these file level properties make up the actual ...


10

Which part of the script is actually taking up most of the time? There are about 5 other steps going on before you actually start deleting stuff. You might want to break your script down into bite-sized tests. For example, instead of creating a temporary connection file, listing a bunch of datasets, listing their contents, counting their records, and then ...


9

By "midpoint" I'm assuming you're asking about a centroid. For polygons, you'll want to cast it to an IArea object (see link for example), and then access the Centroid property. For points, you can simply get the X/Y property of the IPoint object. To get the feature, you can use various IFeatureClass methods such as GetFeature to access it using the ...


9

The trick to feedback is setting ISymbol.ROP to esriROPNotXOrPen and drawing the geometry twice, the first draw displays it, the second draw erases it. Be sure if you're using a multilayer symbol to set the ROP for each layer. public class MyTool : ESRI.ArcGIS.Desktop.AddIns.Tool { private ISymbol m_Symbol; private IPoint m_lastPoint; private ...


9

Features in the most general sense are analagous to records in computer science: In computer science, records (also called tuples, structs, or compound data) are among the simplest data structures. A record is a value that contains other values, typically in fixed number and sequence and typically indexed by names. The elements of records are ...


8

While there is no comfortable editor for label properties available yet, you can achieve the effect of label classes using "data defined labeling": This requires some data preparation, but the results should be just what you are looking for. Also of interest to you might be the new labeling tools by Sourcepole: move label tool … move text labels to a ...


8

You can unselect features with unselect and unselectAll methods of SelectFeature control: selectControl = new OpenLayers.Control.SelectFeature(vectorLayer); ... map.addControls([selectControl]); selectControl.activate(); // unselect any specific feature... selectControl.unselect(vectorLayer.features[0]); // ...or all features selectControl.unselectAll(); ...


8

Sure it is. Depending on what you need: zoom to whole layer right click on layer in Layers list and first item is "Zoom to layer" zoom to selected feature(s) select feature in map and click on icon "Zoom to selection" in the main toolbar or right click on layer in layers list and choose "Open Attribute Table" (there is also icon in the main ...


7

Personally I'd very much welcome functionality and ease of use of ArcGIS Network Analyst extension.


7

High quality map production: it's possible with FOSS, but a bunch of extra work.


7

Another approach to this would be to use the Spatial Join tool. Use the point as your input feature layer as above and the polygon layer as your identity features.Unlike SelectLayerByLocation, SpatialJoin does honor the extent environment. targetlayer = layername joinlayer=arcpy.PointGeometry(arcpy.Point(x, y)) fieldmappings = arcpy.FieldMappings() ...


7

Here's how I would do it: Make sure your data are in an appropriate projected coordinate system. Add a new Double field to the attribute table called Area. Run field calculator on this new field with the expression: !shape.area! and Python as the parser. Run Summary Statistics, performing COUNT on the Name field, and MAX on the Area field we added in step ...


7

I know this is old but I was looking for the same as I don't have ArcInfo for the FeatureVerticesToPoints tools. After using Search cursor solution above I went forward to simplify the code and found that using NumPy Arrays in the Data Access Module a simple and very quick script could be produced. I'm using this as a script tool. Note: The key is the ...


7

Few options. Some crazier :-) than others. The basic strategies are Cluster features Hide/move the top feature Send the click through the top feature ==> Turn on feature clustering strategy Implement your own clustering algorithm, so when a new item is added or modified, your algorithm re-runs and does a nested for-loop check and n*n(-1) checks to ...


7

Yes, there is. Go to Options in the Settings menu and open the tab Map tools. Then you can set the Identify Mode. You probably want the Top down, stop at first.


7

The Feature Class to Feature Class tool is a Conversion tool. The idea is to convert a feature class in one format (e.g. shapefile) to another (e.g. geodatabase). It also allows the user to control the Field Map - i.e. which fields will be copied over. The Copy Features tool simply creates an exact copy of the input features. Note - this tool can also be ...


7

I recommend using the Select_analysis tool which will accept a where clause. arcpy.Select_analysis("C:/CGDP.shp", "C:/New.shp", ' "GDP_TOP10" = 1 ')


7

I doubt it has to do with the number of entries. I just added XY data for an Excel spreadsheet of 50000 rows by 17 columns of text of 200 characters and it exported to shapefile without a hiccup. From the error message page: 001337 : The maximum record length has been exceeded. The record length is the number of bytes used to define all the fields ...


7

I believe you need a field in the attribute table of the feature with a data type of Double. You can call it Rotation or something. This is where the value is stored when you use the rotate tool. Then that field should show in the Symbology/Advance/Rotation drop down.


7

There are two ways to get at the Create Features window from the Editor toolbar: 1) Start Editing. Right-click on toolbar and select "Editor" 2) In the editor toolbar: Editor > Editing Windows > Create Features Alternatively, the right most button on the editor toolbar:


7

In Windows explorer copy and paste the following location in the address bar and replace username with your username on the machine with the arcGIS install on it.: C:\Users\username\AppData\Roaming\ESRI\Desktop10.1\ArcMap\Templates Delete normal.mxt (your mxd template) this will restore you mxd to it stock/original format with all your toolbars and windows ...


6

What about simplifying geometries? http://www.bostongis.com/postgis_simplify.snippet http://stackoverflow.com/questions/1849928/how-to-intelligently-degrade-or-smooth-gis-data-simplifying-polygons Or maybe a combination of WFS, WFS with simplified features and WMS?


6

GeoServer provides a user setting to control the number of decimal places in the geometries which was put in there to speed up WFS serving. Also make sure that the server is compressing the output only if your client can efficiently uncompress it. Finally I've heard good things about tiny OWS in terms of speed.


6

In the attribute table, compute a numeric field with the Python expression !shape.getpart(0).count! The triangles will all have values of 4 (three vertices plus a duplicate of the first one to close the polygon). The islands almost surely will have more than 4: select them based on this count and delete them, or (more safely) set the layer's definition ...


6

These terms specifically relate to the ESRI software and data schemas. A feature class is a set of common geographic features, for example roads, or parcels, or land use, as they are stored in a geodatabase or shapefile, or other storage format. Here is the help file on Feature Class Basics. A feature layer is the representation of a feature class after ...


6

The event is OnChangeFeature.


6

Matt: if the features have common attributes, you can theme them on those attributes. Check Properties > Style and choose Categorized or Rule-based and play around with the settings there.


6

See my LIVE DEMO. Here is working code: <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Title</title> <script src="http://openlayers.org/dev/OpenLayers.js"></script> <script type="text/javascript"> function init(){ options = { div: "map", zoom: 2, center: [0, 0], ...


6

Magnus, What are you intending to do with the OSM data once in a postgis table ? Depending on what you intend on doing with the data (Are you looking to do spatial analysis of highways ? Make a map of a complete city including restaurants and other POIs (points of interests) ? ), your osm2pgsql style files will be a little different. First, osm2pgsql's ...


6

You kind of have catch-22 or at minimum not detailed enough requirements. Specifically - do you want to remove the 1st feature as SOON as the user starts drawing a new feature? Or when they're done? Because you could end up blowing out your 1st feature and user cancels out of drawing 2nd feature and then you have nothing. You have 2 additional things ...



Only top voted, non community-wiki answers of a minimum length are eligible