In the matplotlib library theres a function called legend which is used to Place a legend on the axes.
Example for legend. Tutorials references and examples are constantly reviewed to avoid errors but we cannot warrant full correctness of all content. For example legend MonTueWed Llegend labels of the legend. Legendx y NULL legend fill NULL col parcol border black lty lwd pch angle 45 density NULL bty o bg parbg boxlwd parlwd boxlty parlty boxcol parfg ptbg NA cex 1 ptcex cex ptlwd lwd xjust 0 yjust 1 xintersp 1 yintersp 1 adj c0 05 textwidth NULL textcol parcol textfont NULL merge dolines haspch trace FALSE plot TRUE ncol 1.
When her husband issued a heavy tax on the local people Lady Godiva begged him to stop this oppressive tax called a Heregeld. One of the worlds most famous legends is the story of Icarus the son of a craftsman in ancient Greece. Labels can be a string array character vectors or a character matrix.
She loved her husband dearly but always opposed the way he treated his people. The more the basic example from the official matplotlib legend guide import matplotlibpyplot as plt line_up pltplot123 labelLi. Line plot makePlot legendtopleft legendcLine 1 Line 2 colcred blue lty12 cex08 Example 2.
To modify legend labels. You can easily improve your search by specifying the number of letters in the answer. The below examples show how the fieldset element groups the labels and radio buttons and checklist together.
In the previous example we have used the topleft command to show our legend at the corner in the top left. There is historical evidence of a King Arthur who led the British against invaders. The bbox_to_anchor keyword gives a great degree of control for manual legend placement.
The city of Atlantis was introduced by the Greek philosopher Plato. However the details of the Arthurian legend-the knights of the round table Camelot and Queen Guinevere-are likely made up and exaggerated. Besides that we can also use.