Plotly Legend -TitelPython

Python-Programme
Anonymous
 Plotly Legend -Titel

Post by Anonymous »

Ich möchte im folgenden Code in der Lage sein, der Legende einen Titel hinzuzufügen. Wenn ich mir jedoch die Dokumente ansieht, denke ich nicht, dass es eine Methode dafür gibt. < /P>

Code: Select all

import plotly.plotly as py
import plotly.graph_objs as go

trace0 = go.Scatter(
x=[1, 2, 3, 4, 5],
y=[1, 2, 3, 4, 5],
)

trace1 = go.Scatter(
x=[1, 2, 3, 4, 5],
y=[5, 4, 3, 2, 1],
)

data = [trace0, trace1]
fig = go.Figure(data=data)

py.iplot(fig, filename='default-legend')

Quick Reply

Change Text Case: 
   
  • Similar Topics
    Replies
    Views
    Last post