无法显示绘图条形图

时间:2018-11-22 20:44:10

标签: python pandas graph plotly

[![import plotly.graph_objs as go
import plotly.offline as ply
import pandas as pd

df = pd.read_csv("data.csv")

df_travel = pd.pivot_table(df, values="Passenger_Count", index="GEO_Summary")

data1=[go.Bar( x = df_travel.index, y=df_travel.values, name='Passengers travelled by GEO region')\]

figure = go.Figure(data = data1)

ply.plot(figure, filename='basic-bar.html')][1]][1]

O / P:Web浏览器中的输出html不显示bar及其相关值 ,但是当我在Chart Studio中编辑时,我可以看到图形。我能知道我本地的问题是什么吗? enter image description here

0 个答案:

没有答案