Questions tagged [legend]
A graph legend is commonly used when plotting several sets of data within the same diagram. The legend associates each plot with its corresponding data.
legend
5,167
questions
1
vote
1
answer
39
views
Highlighting or selecting all values from Legend
Why when hovering over the bottom "legend" every time only one of the entries or the last one is highlighted. Is there a way to highlight or even better select all components which have same ...
0
votes
1
answer
54
views
How do you remove pattern_fill legend?
I'm wondering how and if it's possible to remove the legend created by pattern_fill?
This is my data:
#To use non-english characters
Sys.setlocale("LC_ALL", "nb-NO.UTF-8")
library(...
0
votes
1
answer
38
views
Shared legend for 2 Highcharts using React
I want a shared legend for 2 areaspline highcharts. Using react, I am unable to create that shared legend between the 2.
My code:
component.js:
import React from "react";
import "...
0
votes
1
answer
49
views
How to Display Values Next to Legend in React Pie Chart? Getting 'Undefined' Error
I am trying to display value next to legend, but I am getting undefined.
Debugged but no luck, can you let me know how to fix it.
Providing my code snippet and stackblitz below
https://stackblitz.com/...
0
votes
1
answer
334
views
How to customize the legend of Seaborn plot
I was trying to customize the legend of my seaborn plot adding also the values into the legend just after the color and the name of each x entry. In this case, it will be color, x value, y value.
...
0
votes
1
answer
41
views
Change layout of legend2 in plotly
How to change layout of legend2 with fig.update_layout()?
import plotly.express as px
import pandas as pd
numbers = pd.DataFrame([[1,2,3,4], [2,3,4,5], [5,7,8,8]])
asdf = px.line(numbers)
asdf = asdf....
0
votes
0
answers
25
views
How to customize legends in Power BI for shapefile?
I am working with county level shapefile for China and for each county I have some values.
I have uploaded the shapefile in Json format in Power BI like below.
I wanted to create legend as below map ...
0
votes
0
answers
20
views
how to mpchart legend text Color change in android
When I googled the information, it said that I could use setCustom.
Only form, not label text is allowed in the entry in this section.
What I want is to make the legend's form color and label color ...
0
votes
1
answer
34
views
Legend of the library Fantaxtic
I am running the library fantaxtic in R studio. I want to make a bar chart or something like that. However, in the legend I don't want any title in the legend and the category Other is located at the ...
0
votes
1
answer
36
views
One variable with three colors, but only one color on the legend
I have two variables in my table. I want one of them to appear with three colors on the graph, but only one color on the legend. How can I remove the NAs, which don't correspond to separate variables, ...
0
votes
1
answer
48
views
Removing underscores from ggplot2 boxplot [duplicate]
I would like to remove an underscore out of my ggplot2 boxplot (the head of fill "fungicide_treatment".
I already tried to change the column head in my excel data file, and I tried already ...
0
votes
1
answer
39
views
Ggplot2 fill legend labels not in correct order
I am creating the following graph with ggplot2. The problem is that all labels show in the chronological order except the last three. I cannot work around it. Does anyone see what causes the issue and ...
0
votes
1
answer
41
views
MS Reporting Services stacked bar chart with custom series fill color shows wrong legend colors
I have a SSRS stacked bar chart with Regions (on the x axis) as category and Countries as a Serie. I have a property from the Dataset called "Fields!ReportColor.Value" which I used in the ...
1
vote
1
answer
42
views
Legend for boxplot graph layers
I've made this boxplot graph
# Tamanho do gráfico em polegadas
plt.figure(figsize=(11, 6))
# Gráfico
ax = sns.boxplot(x="CÓD. ESTAÇÃO", y ="FERRO", data=df_FERRO, linewidth=1.0, ...
0
votes
0
answers
51
views
How do I create a color legend on my page without a chart?
I'm using razor on my site which uses ASP.NET Core 7.0. There's a place where I need a color legend, but a google search isn't really turning up what I need. There have been plenty of charts that ...
1
vote
1
answer
41
views
how to change the legend sharp to circle
library(ggplot2)
food_choices <- c("Pizza", "Pasta", "Sushi", "Caesar Salad")
counts <- c(17, 10, 8, 11)
table <- data.frame(food_choices, counts) # ...
1
vote
0
answers
57
views
Multiple columns of df show as 1 single label in legend and show how many columns are representing on matplotlib
I have a dataframe that contains temperature of 3 meteorological networks and each ones contains a certain meteorological stations, so the columns 0 to 34 are stations of 'REDMET' meteorological ...
0
votes
1
answer
20
views
How to turn off lines in raster fill label mixed legends ggplot
I'm plotting points and two sets of spatial lines (roads and rivers) on top of a categorical raster. I can define the colors and labels of the rasters and give that legend a title and it looks great. ...
0
votes
1
answer
78
views
How can I plot multiple legends for multiple geopandas plot layers?
I want two show both legends for both of my plot layers but it shows only just one legend. How can I fix this?
import geopandas
from shapely.geometry import Point
from shapely.geometry import Polygon
...
2
votes
1
answer
820
views
own legend and show/hide series echarts
I prepare my own legend with checkboxes for echarts. When a checkbox is clicked, it invokes a special function to remove data from the chart. I remove or add this data from series and reload chart.
...
0
votes
1
answer
61
views
Force keys size to be smaller in multiple lines legend in ggplot
Is there any way to force legend key sizes to be independent from line height when we have legend text with multiple lines? I tried legend.key.height, ggtext::element_textbox_simple, and guides but ...
0
votes
1
answer
78
views
Sharing multiple legend symbols within a ggplot2 scatterplot
I am trying to create a simple scatterplot in ggplot2 that has a unique shape for each factor level but certain colours are the same. I can achieve this, but would like a nicer looking legend where I ...
0
votes
0
answers
23
views
Highmaps mapbubble legend moves when zooming in the map
I use Highmaps to display bubbles on a mapline. Everything works well but if I display in the legend the color axis and the size of bubbles, there is a strange behavior when I zoom in the map.
The ...
0
votes
1
answer
62
views
What is the color legend in Android Studio kotlin code?
I'm learning kotlin currently and trying to understand the studio capabilities.
I see that some of my code is in different color. While I did manage to figure out most of the color legend, Yellow and ...
0
votes
2
answers
64
views
legend in bokeh UMAP shows only one entry
Hi there I just managed to get this plot done in bokeh, so I imagine there are many things that could be improved. Nonetheless, what bothers me the most is that I cannot figure out how to have all ...
0
votes
1
answer
31
views
Adding a manual legend without extending the plot
I have been trying to add a manual legend to my graph using the following code. However when I add this code it extends the x-axis and I don't understand why.
df %>%
group_by(Site) %>%
...
0
votes
1
answer
32
views
Do gca().lines and legend.get_lines() return the lines in the same order?
Do gca().lines and legend.get_lines() return the lines in the same corresponding order?
If not, is there a way to get corresponding legend lines from gca().lines?
0
votes
1
answer
73
views
How can I center my legend labels in ggplot?
I created a legend with a range of rates for a map. Currently, my labels appear adjacent to the breaks, I want the labels to appear adjacent to the center of each level.
Here's my code...
ggplot(...
1
vote
1
answer
31
views
Order ggplot legend differently than elements in plot
Is there a way to order a legend in ggplot differently than the elements on the plot. for example I want the legend to be ordered Calanoida, Cladocera, Rotifera, and Cyclopoida but I want the ggplot ...
1
vote
2
answers
60
views
Unwanted characters in GGPlot 2 legend entries for stacked area chart
Good day,
I need to prepare a graph showing the proportions of the various biomass components, but it is showing ,1 after each component in the legend in R, Ggplot2. I only want to see the list of ...