考虑下面的代码,它使用了这个historical_rates(today)
函数。我想收取除周末以外的所有日子的费率,是否有一些示例说明如何做到这一点?
import datetime
from fixerio import Fixerio
today = datetime.date.today()
fxrio = Fixerio()
fxrio.historical_rates(today)
'''
{u'base': u'EUR',
u'date': u'2016-05-27',
u'rates': {u'AUD': 1.5483,
u'BGN': 1.9558,
u'BRL': 4.031,
u'CAD': 1.456,
u'CHF': 1.1068,
u'CNY': 7.3281,
u'CZK': 27.028,
u'DKK': 7.4367,
u'GBP': 0.76245,
u'HKD': 8.6735,
u'HRK': 7.4905,
u'HUF': 314.21,
u'IDR': 15157.25,
u'ILS': 4.2938,
u'INR': 74.867,
u'JPY': 122.46,
u'KRW': 1316.98,
u'MXN': 20.6611,
u'MYR': 4.5554,
u'NOK': 9.282,
u'NZD': 1.6586,
u'PHP': 52.096,
u'PLN': 4.3912,
u'RON': 4.5034,
u'RUB': 73.7516,
u'SEK': 9.2673,
u'SGD': 1.536,
u'THB': 39.851,
u'TRY': 3.2928,
u'USD': 1.1168,
u'ZAR': 17.4504}}
'''