我有一个项目,我需要在www.wikizero.com上获取一些信息,因为维基百科在我的国家/地区不适用。.我试图在https://www.wikizero.com/tr/Mustafa_Kemal_Atat%C3%BCrk这个网站和{{1}上制作API },在此update_fig()
下,“穆斯塔法·凯末尔·阿塔图尔克[n 2](1881 [n 3]-10Kasım1938),Türkmareşalve devletadamı。 kadarcumhurbaşkanıolarakgörevyaptı。”这是我想在网站上使用的内容,但我只能接受。
当我编写此代码时
def update_fig(dataview_value):
# define your weekly OR monthly dataframe
# you'll need to supply df_weekly similarly to df_monthly
# though DO NOT modify these, see note below!
df = df_weekly if dataview == 'weekly' else df_monthly
dfkey = 'Week' if 'week' in df.columns else 'Month' # eh, worth a shot!
figure={
'data': [
go.Bar(
x = df[dfkey],
y = df['CheckTotal'],
name = 'Take Home Pay',
),
go.Bar(
x = df[dfkey],
y = df['EarnTotal'],
name = 'Earnings',
)
],
'layout': go.Layout(
title = 'Take Home Pay vs. Earnings',
barmode = 'group',
yaxis = dict(title = 'Pay (U.S. Dollars)'),
xaxis = dict(title = 'Date Paid')
)
}
return figure
它向我展示了这一点。
那么我该如何接受这个阻拦。 enter image description here