cli.py 文件源码

python
阅读 18 收藏 0 点赞 0 评论 0

项目:trader-bot 作者: ricco386 项目源码 文件源码
def get_assets(self):
        """Assets and asset pairs availalbe at the exchange

        Get all available assets and also traiding asset pairs from the
        exchange.
        """
        table = [
            ['ASSET', 'ALTNAME', 'DECIMALS']
        ]

        for asset, props in self.kraken.get_assets().items():
            table.append([asset, props['altname'], props['decimals']])

        print(tabulate(table, headers="firstrow", numalign="right"))
        print("\n")

        table = [
            ['PAIR', 'ALTNAME', 'DECIMALS']
        ]

        for pair, props in self.kraken.get_asset_pairs().items():
            table.append([pair, props['altname'], props['pair_decimals']])

        print(tabulate(table, headers="firstrow", numalign="right"))
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号