Tag Info

New answers tagged

2

You can try using the Maplex labeling engine which will give you more control than the standard labeling engine. In the labeling toolbar, enable Maplex. There are several options in which you can adjust the settings for feature weights and overlapping labels. See the ESRI documentation. Weights can range from 0 to 1,000. Features with high weights ...


0

This is possible by assigning a higher weight to the line layer's features than to the point layer's labels. Open the Properties dialog for the line layer, and choose the Labels > Placement option, then set a High value for the Feature Weight. This causes ArcMap to move those labels which would have overlapped the lines, or to omit drawing them where ...


3

Previously I have saved as a layer file and then imported the symbology from the layer. To save as a layer file right click on the layer in the table of contents and select 'save as layer file'. To import the symbology click on the open folder in the raster properties dialog. then browse to the layer file saved to disc Note: if the layer symbology is ...


2

you can use raster calculator to set your 0 values to NoData. Con(condition, value if true, value if false) will set the false value to Nodata if it is left blank. in your case, you could use Con(raster== 1, 1) a more generic code would be Con(raster!=0, raster) when you convert to polygon, NoData pixels will be ignored. Note that you can make ...


0

I have many fonts installed on my OS. About 1500 really. Apparently other people have had slow performance with many fonts installed http://forums.arcgis.com/threads/8386-Desktop-ArcGIS-10-Really-Slow/page3


0

In a comment you mention you are using Maplogic, which appears to be a commercial add-on similar to the old DS Mapbook extension. My first suggestion would be to start with their help files and/or support to see if you can change the grid cell naming scheme and if so how. Their example book shows something very similar to what you are asking for - a numbered ...


2

Under the File menu, see the Sign In option: Once you've signed in, you will be able to add data to ArcMap from ArcGIS Online - rather than hitting the + of the Add Data button, use the dropdown beside it: You will also see My Hosted Services in the ArcCatalog window:


0

After some testing, the fastest way I can find to do what you want is to digitize your blue lines as new polylines. All you need to do is snap to the endpoints of each cirque line to close off the areas that you want. It can be one continuos new line in cases like the bottom of your image, but if you don't want that middle cirque in the upper part of your ...


2

When you digitize polylines if you want to make polygons from them is to make sure that they are crossing or activate the snapping environment (or directly draw polygons). If it is too late, you can still clean your polylines using the Extend tool but you need standard or advanced licence to use this tool. If you don't, you can try with integrate, which ...


2

Here's what I think you are asking: 1) Open the Attribute Table 2) Export the table to a new table 3) Save the type of table you want in a location you want 4) Edit the new table all you need 5) Join the new table to the old and 6) Calculate the new field values in the old table from those in the joined new table


3

When you bring in a csv, Arc does its best to determine the appropriate field types and as you have found it doesn't always get it right. One solution is to use a schema.ini file (see bottom of page) to explicitly set the field types for your columns. There are several related (duplicate?) questions here on the GIS SE if you search for 'schema.ini'. More ...


-3

I have arcgis 10 and I think you can not import CSV files into the geodatabase, much less save as .DBF. First, try to add to ArcMap, then export to geodatabase.


0

I found a current approach to this by adding WCF data to the Arcmap.exe.config file. This, however is just a workaround. I would prefer WCF go after an external config.


0

IApplication.NewDocument http://help.arcgis.com/en/sdk/10.0/arcobjects_net/componenthelp/index.html#/NewDocument_Method/00230000003s000000/ to create a new empty document then just open the new document IApplication.OpenDocument http://help.arcgis.com/en/sdk/10.0/arcobjects_net/componenthelp/index.html#/OpenDocument_Method/00230000003t000000/ to teminate: ...


0

Similar, but different to above: import arcpy fc = "YOUR FC" fields = [f.name for f in arcpy.ListFields(fc) if f.Type == "String"] cur = arcpy.UpdateCursor(fc) for row in cur: for field in fields: try: row.setValue(field) = row.getValue(field).upper() except: pass row.updateCursor(row)


1

Here's a quick example: fc = "whatever" fields = ("Name", "Addy", "Stuff") with arcpy.da.UpdateCursor(fc, fields) as cursor: for row in cursor: row[0] = row[0].upper() row[1] = row[1].upper() row[2] = row[2].upper() cursor.updateRow(row) And here's the ArcGIS manual for the da.UpdateCursor


6

The following example shows how to integrate the built-in python method .upper() with the arcpy update cursor. This example first tests if a field is of type String then checks each row within that string for lowercase values. If there are lower case values, the row is updated with all upper case. import arcpy fc = r'C:\temp\test.gdb\yourFC' desc = ...


1

Here is how you can use .upper() in python: data = "lower case data" upper_case_data = data.upper() print upper_case_data it can also be used directly with a string print "lower case data".upper()


3

Figured it out function FindLabel ( [NAME] ) { return [NAME]+'\nNational Forest'; }


20

You can use basemap layers to solve this. Once you are happy with the symbology of your layers you can right click the data frame and select New Basemap Layer (see below) which is similar to a group layer. You can then drop the layers into this group, it will redraw them once and then 'store' this view rather than redrawing every time you make a change. If ...


1

You could save your functions in a raster function template and apply this template to other rasters using the Edit Raster Function tool (Standard or Advance license needed).


2

Yes, absolutely, you can do that. The principle is to define a function-based index. The steps are like this: Assume I have a table like this: create table customers ( id number primary key, name varchar2(30), longitude number, latitude number ); 1) Define a function that transforms the long and lat columns into a geometry: create or replace ...


0

If your script knowledge is limited have you considered doing this in model builder? The model below will identify the minimum cell value and extract all cells with this value to a new grid.


1

You can use Get Raster Properties (Data Management) to extract minimum elevation values. import arcpy inputRaster = r'C:\temp\dem.img' raster = arcpy.GetRasterProperties_management (inputRaster, "MINIMUM") To extract the information so that you can use it in a command such as Con or Reclassify use the following: elevMin = raster.getOutput(0) To put ...


1

I had thought that the normal store relative path covered images, however I think this may be what you are after: Right click your image and go to properties, and then tick the save image as part of document (see below). This should then stop it losing the path, and keep the image with the .mxd


1

Another alternative to both Ian and Fezter's answers is to use the INSTR and MID VB script functions (This particular expression does not require you to be in an Advanced Expression mode): MID([Your_Field], 1, INSTR([Your_Field]," ")) INSTR function has the following parameters: InStr([start,]string1,string2[,compare]) MID function has the following ...


4

An alterntive to ian's suggestion, you can change your label expression to something like the following. By importing the regular expression module, you can create function to only display numbers at the beginning of a string. def NumberLabel(addressField): import re return re.search('^\d*', addressField).group() As per Ian's example, use python ...


6

You can put this as the label expression for the feature: def FindLabel(yourField): if yourField is not None: split_field = yourField.split(" ")[0] return str(split_field) else: return None Using Python as the parser and checking the Advanced box. Replace yourField with whatever field you are using to label.


1

Since you have a shape file with polygons and the raster you can use the tool Tabulate Area from Spatial Analyst. The input dataset that defines the zones will be your 'fishnet' and the the dataset that defines the classes your raster. The output will be a table like this: value | value 0 | value 1 ID1 | 0 | 2 ID2 | 1 | 1 the first ...


1

This is clearly defined and explained in the Help. ArcGIS 10.2 GWR Help ArcGIS 10.2 OLS Help


3

I would make two changes: Make sure your indentation is correct Use len() to count the characters. Make sure you are writing to a text field. def reclass(f1): if len(f1) >= 4: return "Yes" else: return "No" Label = reclass( !HUB! )


0

Select by Attributes: char_length(FIELD) >= number Field Calculate on the selected records


4

This probably should have been a comment, but got too long. How does ArcMap do what? It can display data without a spatial reference / coordinate system (SR / CS), but try to add other data that's really in a different CS. They're not going to overlay unless you happen to set the data frame's coordinate system to the unknown data's CS. ArcMap does not ...


3

I would use random.choice() to make a random selection from the .csv file and insert that into your FC rows using an Update Cursor. import arcpy, csv, random # Read csv file with names file = r'C:\path\to\your\file.csv' reader = csv.reader(open(file, "rb"), delimiter = ",", skipinitialspace=True) listofnames = [name for line in reader for name in line] # ...


2

import arcpy import random import csv fc = "C:/stuff.shp" csv_rows = [] with open("C:/some.csv", "rb") as csvfile: reader = csv.reader(csvfile) for line in reader: csv_rows.append(line) with arcpy.da.UpdateCursor(fc, ("FIELD2UPDATE")) as update: for row in update: random = random.randint(0, 49) value = csv_rows[random] ...


2

In order to add another map view over another area you would use another data frame (Insert > Data Frame). Learn here how to work with multiple data frames in page layout. You can switch between data frames in Table of Contents and zoom as required. In Layout view, you can move data frames as needed.


2

Typical - after spending hours on this, I realised the answer a few minutes after posting the question to Stack Exchange. At least others can learn from my stupidity. I needed to add a 3rd control point, in order to allow the affine transformation to apply the correct adjustment:


2

Right click on the raster layer in the TOC and select "Save As Layer File". Add your other raster to map, go to Layer Properties - Symbology tab, click import, find the saved layer file. Alternatively, you can apply the symbology of any raster in your map document to any other raster in your document by also clicking import but selecting the source raster ...


6

Many thanks to @Erica for the reply, which for some reason didn't work for me. But it did put me on the right track to finding a solution, which was to use the Minimum/Maximum Stretch, in combination with the Edit High/Low Values option: Importing this symbology into the other rasters caused the correct stretch to be applied to all images.


0

There are several ways to get at this in ArcMap that all revolve around the same concept. If you only have 5 classes like you show in your question you can play with the individual color bins in at least two distinct ways. Make the lightest one “No Color” and grade up from there and setting a transparency. This is not much less cumbersome than the work ...


2

I know that your question is ArcGIS\ArcMap specific, but, maybe you are in the mood to try something different. QGIS can do what you wan't. Style your layer with singleband pseudocolor. Create a new color ramp using gradient color. For one of the colors use 0 for the alpha chanel And press classify. The result will be something like this: Note ...


2

I've attached an image showing what you need to do for the first step. Namely, turn the Shapefile into a Featureclass. A Featureclass can only reside inside a Geodatabase (aka GDB). Alternately you can create a GDB and import your Shapefile into it by R-click, etc. See this image below. As Alex Tereshenkov said - You can only enable attachments to a ...


2

Great question -- I needed to do something similar recently, and it is well-hidden! In the Symbology dialog that you show above, you need to scroll down. That will bring you to the "Stretch" dialog. T By default, ArcMap will analyze the histogram and come up with its own best fit based on the statistics of a specific image. This optimizes the color ramp ...


3

Attachments can be enabled only on feature classes stored within a geodatabase (this can be any type of geodatabase - personal, file, or enterprise). You cannot attach your files to a shapefile because there is no container the data can be stored in. To convert your shapefile to a geodatabase, you can use a GP tool Feature Class To Feature Class ...


6

The only way I know of to do this without creating many feature layers (one for each level of transparency) is to create a raster with an alpha channel. Here is one possible workflow you can try: Use Polygon to Raster to convert your polygon features to a raster. Reclassify the data as desired (using 8-bit unsigned integer with values from 0-255 works ...


2

There is a workaround to do graduated transparency in the Esri Knowledge Base as a Technical Article entitled HowTo: Create graduated or proportional symbol transparency. However, I have not tested it. It dates from ArcGIS 8.3 and uses Convert Features to Graphics and Convert Graphics to Features (which was then only a Developer Sample). Even if it ...


0

I'm calling this a workaround since I'm not sure if there is a better way to deal with the typeloadexception, but I changed my CompilerParameters to generate to a file: outpath (where the outpath is the assembly cache directory + somefilename.dll). Now it works. CompilerParameters options = new CompilerParameters(); options.GenerateExecutable = false; ...


2

I found this good discussion at http://www.cartotalk.com/index.php?showtopic=7109 and thought it would be useful to add to GIS.stackexchange for posterity. in ArcMap 10.2, choose > Windows > Image Analysis in the top panel, select the input image in the Processing section, choose the first tool (Clip) this adds a new temporary raster to the TOC right-click ...


2

If you leave the cell size blank you are telling ArcMap to choose its own, by your admission you've indicated that the data is dense so a small cell size would be suitable. e-006 means 6th decimal place (so 1e-006 is 0.000001). Is your source data in geographic coordinates (lat/lon)? this would explain the difference in cell dimensions i.e. stored in ...


0

the workaround is to work in vector analysis. You can create a fishnet with squares of the size of your cells, then you use spatial join(with "JOIN_ONE_TO_ONE" option) to get the count of the lines. At the end you can convert the vector grid to a raster.



Top 50 recent answers are included