:
layout = plotly.graph_objs.Layout(
legend=dict(orientation="h")
)
예컨대
import plotly
layout = dict()
trace1 = plotly.graph_objs.Bar(
x=['giraffes', 'orangutans', 'monkeys'],
y=[20, 14, 23],
name="Stackoverflow's personal zoo without any real name but some really long text"
)
trace2 = plotly.graph_objs.Bar(
x=['giraffes', 'orangutans', 'monkeys'],
y=[12, 18, 29],
name="Another zoo which doesn't have a name but but lots of superfluous characters"
)
trace3 = plotly.graph_objs.Bar(
x=['giraffes', 'orangutans', 'monkeys'],
y=[15, 12, 32],
name="Yet another zoo with plenty of redundant information"
)
data = [trace1, trace2, trace3]
layout = plotly.graph_objs.Layout(
barmode='group',
legend=dict(orientation="h")
)
fig = dict(data=data, layout=layout)
plotly.plotly.sign_in('user', 'token')
plot_url = plotly.plotly.plot(fig)
기본 전설 수평 전설
대답 도움이 되었습니까? –