Questions tagged [legend]

The description of the types of features included in a map, usually displayed in the map layout.

Filter by
Sorted by
Tagged with
9
votes
5answers
8k views

Displaying dynamic table in Data Driven Pages environment?

I am creating a map series that has many polygons per sheet. There is annotation for the polygons however some polygons are very small with no annotation for them (annotation would completely hide a ...
10
votes
1answer
2k views

Adding labels with symbols to legend in ArcMap?

I'm creating a map with ArcGIS Desktop v10.2.2, showing museums as points. The museums layer has no symbol and the labels are made of a circle filled with color with the ID inside, taken from the [ID] ...
14
votes
4answers
24k views

Showing only legend items that are actually displayed on map in ArcGIS Desktop?

Using ArcGIS Desktop, is there a way for the legend, to only show the subitems that are displayed on the map?
30
votes
7answers
25k views

Using continuous color band for raster legend in QGIS composer legend?

I'm looking for a way to insert continuous colour legend for a raster layer. I managed to create discrete symbols with values along the bar, but I would like to have a continuous bar with some values ...
7
votes
3answers
3k views

Subscript labels in QGIS legends

Is it possible to include subscript and superscript text in the title of a legend item in QGIS ? I have tried using <sub>some text</sub> but this just appears in the title with no change ...
7
votes
3answers
7k views

Resizing symbols in QGIS Print Composer legend?

I am trying to map a count data type via graduated symbol against a chloropleth and the legend is too big. The circles of the graduated symbols are the actual size of their corresponding values in ...
5
votes
2answers
579 views

Is there a Legend Limiter in QGIS?

Is there in QGIS a function or a plugin that works similar to Legend Limiter in ArcGIS? The attribute I want to show in my legend has many possible values, I want my legend to only show those values ...
11
votes
7answers
2k views

Platforms for repetitive automated mapping?

I could give a lot of examples, but imagine you have to do, for example, a study in 10 different locations and have to generate a lot of maps with the same layout, legend. Maps can contain vector ...
5
votes
2answers
2k views

Adding legend to canvas in standalone PyQGIS application? [closed]

I am trying to develop a standalone PyQGIS application. The map display does not pose any problems, but I do not know how to add a legend to the canvas.
6
votes
1answer
2k views

Showing only some layers in QGIS legend?

My QGIS 2.8.2 standalone app provides several decorating layers (e.g. cartographic grid, background layers, reference points) which should be not changed by the user (neither editing nor hiding), as ...
8
votes
6answers
2k views

Creating legend with new data defined symbols functionality in QGIS?

I have a large geology data set that I need to display using an industry standard set of symbols and colours. The symbols and colours are attributes of the data. I have been using the data defined ...
5
votes
3answers
2k views

Resequencing Legend Items using ArcPy?

I create various layers programmatically using ArcPy. I can adjust how the layers are sequenced using the arcpy.mapping.MoveLayer command. However, I want to have the legend reflect a different ...
4
votes
4answers
1k views

Why are size-scaled symbols missing from map layout legend?

I have a designed a map using a scaled simple marker symbol. It is a rule-based design and symbol scaling is done by the siye assistant based on a field value for any of the rules in the same way. ...
2
votes
2answers
2k views

Add a legend in an ArcGIS Javascript API

I am quite new to Javascript. I have made a html script that includes services I published to ArcGIS for server. It all does exactly what I want and I made it by copying working scripts together and ...
12
votes
9answers
21k views

Manually classifying graduated data outside of range in ArcGIS for Desktop?

I have two shapefiles representing grids with values that are symbolized with graduated colors, shown below: You can see that the two shapefiles encompass similar ranges of data, but assign slightly ...
8
votes
3answers
3k views

Label legend interval with number of elements in ArcMap?

I have made a series of choropleth maps in ArcMap 10. When I classify the interval the bottom of the dialogue tells how many elements are in the class. Is it possible to have this number ...
5
votes
2answers
1k views

Creating new legend using ArcObjects?

I am trying to add simple legend to the map. I wrote some simple test code below to see what happens but it did not work. var map = activeView.FocusMap; IGraphicsContainer ...
14
votes
1answer
20k views

Allowing for multiple lines in legend of ArcGIS Desktop?

How can I force the description text in my legend to occupy more than one line? This is basically the same question as Forcing long layer names to multiple lines based on specified legend width in ...
2
votes
1answer
347 views

Updating Layer tree after changing symbology with PyQGIS

When I change symbology for a given QgsVectorLayer (QGIS 2.14.16 LTR) by r=iface.activeLayer().rendererV2() r.symbol().symbolLayers()[0].setColor(0,0,255,255) as shown here: and refreshing the map ...
5
votes
2answers
2k views

How to display multiple attributes in a QGIS Composer legend?

I have a polygon layer which has a number attribute and a text attribute. When I make a legend in the composer, it automatically chooses the number to display while I would like to have both the ...
5
votes
1answer
586 views

Setting layer name in composer legend as “Hidden” using PyQGIS?

Is there a way to hide a layer name in the composer legend using pyqgis as we do from the legend properties (see picture)? The only way I've found so far is by changing the layer name in the composer ...
4
votes
1answer
487 views

Changing legend item text with pyQGIS?

Using code I found at Go through items in a composer legend (QGIS 2.6) I can access the the layers in my legend fine. However, I have layers that are styled by category and I can't figure out how to ...
3
votes
1answer
2k views

Filter MapComposer legend to only show layers visible on the map

I have written a function in Python / PyQGIS (no standalone application, so copy/paste it to the Python console editor to run it) that takes a VectorLayer as argument, creates a MapRenderer object for ...
2
votes
3answers
3k views

Converting from ArcGIS layout into Google Earth as kmz with legend?

How to display an ArcGIS legend in kmz or kml file? I am trying to do so in conversion tool of ArcGIS but while exporting it to Google Earth it is not showing the legend.
2
votes
1answer
66 views

removeGroup() in QGIS 3

I am updating a plugin from QGIS 2 to 3. I need to iterate through the groups (the names are dynamic) and remove them with their respective child layers. I need to get a list of groups and then ...
2
votes
1answer
221 views

QGIS Print Composer - Display Symbols for Empty Classes?

I am working on a map of mortality rates for several racial/ethnic groups and I have created custom classes to encompass the rates instead of the QGIS classes created through its various modes. This ...
1
vote
1answer
1k views

1-band raster colour table workaround in QGIS

Does anyone know what the workarounds are for the 1-band raster colour table plugin in QGIS? Currently I find it will run once, then crash on the second iteration. The workaround I use is to delete ...
29
votes
1answer
31k views

Raster legend in R: how to colour specific values?

I have an elevation model plotted in R r <- raster("example.dem") plot(r, col = topo.colors(20)) Some of the values are below sea level (0), and I'd like to have those display in red. How can I ...
18
votes
1answer
34k views

How to Add/Remove Legend with Leaflet Layers Control?

I have two overlays http://02d0c8c.netsolhost.com/dev/lcb_census_layers3.html that can be turned on and off with a Layer Control. I’d like the legend for each layer to turn on/off along with the ...
10
votes
1answer
5k views

Is there a way to show a layers feature count in the TOC?

I'm using ArcGIS 10. In ArcMap's table of contents (TOC), is there a way to have the "Layer Name" automatically show a count of the total number of features in each layer? I was thinking the TOC ...
8
votes
2answers
3k views

Is it possible to change legend symbols in the QGIS print composer legend?

I have some layers with very complex data-defined symbols. If I use a legend in the print composer these symbols are not drawn correctly. Is there a way to change the legend-symbols with pyqgis, so I ...
11
votes
1answer
1k views

Is there cartographic convention to ordering legend items (high-low or low-high)?

When you symbolise a layer in ArcMap, the symbols are ordered from low value to high value by default. Is that necessarily "correct"? I've never officially studied cartography - is there a convention ...
10
votes
2answers
5k views

How to create a vertical scale bar in ArcMap?

Wondering if anyone out there knows how to create a vertical scale bar in ArcMap? With text I can adjust the angle. Is this possible with a scale bar as well?
9
votes
3answers
1k views

Setting symbol descriptions of ArcMap layout legends from table?

ArcMap has the ability to show an extended description for each item in the symbol list. How can I populate that property from a table? The goal is to avoid having to edit each symbol one by one in ...
23
votes
1answer
11k views

Getting legend label on multiple lines in QGIS?

This question was posted in 2011, and someone has said that QGIS now allows multiple lines for legend entries, but no one mentioned how to do this. I am running wein 2.8.1 and I cannot figure out how ...
12
votes
1answer
3k views

How to automatically format the legend labels? in QGIS

I have to do 10 maps (for a start) with "style" -> "graduate" with quantile mode. I need to format the label of the different ranges so that the legend looks comprehensible: Instead of having 1.0000 ...
9
votes
2answers
8k views

Placing label designs in legend of ArcGIS Desktop?

I'm working in ArcGIS 9.3.1 and apart from "regular" slayers with symbology, I have a few layers which I do not show their symbol on the map, but only their label (for example: cities layer in which I'...
8
votes
1answer
4k views

What's the QGIS Legend Format Syntax to label percentage values?

I asked a question about formatting legend text a while back and I'm happy to see the issue has been solved in QGIS 2.6: How to remove trailing zeros from QGIS Graduated Style Class labels? But I'm ...
6
votes
1answer
9k views

How to create leaflet legend for points

I have points like this in a leaflet map. The points come originally from a GeoJSON file and I used L.circleMarker to convert them to circles. How can I create a legend for these points? Based on ...
5
votes
2answers
2k views

Different legend properties with ArcGIS API for JavaScript

I have a map template that I use to display a variety of feature layers and dynamic layers. I have found a snippet of code to add the legend to my map: //add the legend dojo.connect(myMap, '...
4
votes
1answer
2k views

How to change text legend orientation from right to left reading with arcpy

I working on mxd with ArcMap 10.3 . The default's legend properties is- Layout - left to right reading (Marked with a red ellipse) : when it unmarked i get this legend: i want to know if there a way ...
4
votes
1answer
135 views

Indenting subitems in QGIS Composer legend?

My legend looks like this: I would like the items under "Roads & Trails" to be indented to the right. Likewise for the items under "Streams". The spacing controls don't affect this. I could add ...
3
votes
2answers
1k views

Replicating QGIS color ramp style in R?

I want to use rgdal to plot a shapefile graduating the colour of features according to the values of one field (density). I couldn't find online detailed indications on how to do it and the package ...
3
votes
2answers
6k views

Adding Leaflet legend?

I am trying to add a legend to my leaflet map and no matter what I try I cannot get it to display properly. I have imported a point level geojson into my map and I have styled the points in a similar ...
10
votes
1answer
5k views

Forcing long layer names to multiple lines based on specified legend width in ArcGIS Desktop?

Do to various limitations I almost always create static (graphic) legends but I do have the occasional map where impeccable cartography is secondary to functionality hence a dynamic legend is ...
9
votes
1answer
5k views

Decreasing distance between legend's items in R?

I'm trying to create correct choropleth() map in R using GISTools package. I use choro.legend() to display my legend. However I can't create either correct legend placement, AND/OR I don't understand ...
7
votes
1answer
2k views

Legend of a raster map with categorical data

I would like to plot a raster containing 4 different values (1) with a categorical text legend describing the categories such as 2 but with colour boxes. I've tried using legend such as : legend( 1,-...
4
votes
1answer
844 views

How to align QGIS legend items to the right?

Is there a way to align QGIS map composer legend items to the right, for right-to-left languages? There is only a title alignment option. Furthermore, I found this ticket from 4 years ago regarding ...
4
votes
1answer
382 views

Manage space in legend print composer QGIS

I am struggling to figure out how to manage space in the legend. I have extra space between some items in my legend, which I would like to remove: How can I manage these spaces? I built my legend ...
4
votes
1answer
639 views

Is it possible to print one item legend item in italic in print composer?

Is it possible to have one item in italic font (species names) and the rest in "normal"? I use QGIS 2.6. The legend consists of two items which should be written normal (trap positions and ...