Skip to main content

All Questions

0 votes
0 answers
29 views

How to plot the legend with combined_plot (ggplot2)

I created this script to display some environmental impacts for my research. `legend_plot <- ggplot(data_longGW, aes(x = Crop_cycleGW, y = kg_CO2_eq, fill = Category)) + geom_bar(stat = "...
Guido Evangelista's user avatar
0 votes
1 answer
1k views

How to plot a barplot with different hatch and edge color with legends using matplotlib?

I would like to plot a barplot where bars have a different hatch and edge color using Matplotlib with its proper legends. I tried to plot but I couldn't generate proper legends with this code: import ...
Kamran Ansari's user avatar
1 vote
0 answers
220 views

ChartJS Stacked Bar Chart Display Stack Names in Legend

I have a stacked bar graph and wish to divide the data labels in the legend into groups based on the stack id/name to which they relate by including the stack id/name as header for each group of ...
dickey's user avatar
  • 21
0 votes
0 answers
115 views

Is there a way to breakdown a legend of plotly python for combined chart?

As in subject of my question. I was trying few approaches to solve this issue, but I have run out of ideas. How can I display in legend 12 small rectangles with symbology of individual month (and ...
Jaro's user avatar
  • 1
0 votes
1 answer
32 views

ggplot2 single barchart legend doesnt appear

I have a dataframe in the following format with 10 rows of data (listed below). This is a list of obese children in Birmingham (England) by districts. I am plotting this data in a barchart using ...
MD1's user avatar
  • 11
7 votes
2 answers
14k views

Add horizontal lines to stacked barplot in ggplot2 in R, and show in legend

I have a stacked barplot, something like the example below. I want to add one or two sets of horizontal lines (specifying colour and line type) across each bar, at different values for each bar, and ...
CCID's user avatar
  • 1,408