OnePy.py 文件源码

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

项目:OnePy 作者: Chandlercjy 项目源码 文件源码
def get_analysis(self, instrument):
        """??????????"""
        # pd.set_option("display.max_rows", len(x))
        ohlc_data = self.feed_list[0].bar.df
        ohlc_data.set_index("date", inplace=True)
        ohlc_data.index = pd.DatetimeIndex(ohlc_data.index)

        dbal = self.fill.balance.df

        start = dbal.index[0]
        end = dbal.index[-1]
        capital = self.fill.initial_cash
        tlog = self.get_tlog(instrument)
        tlog = tlog[tlog["units"] != 0]
        tlog.reset_index(drop=True, inplace=True)
        analysis = stats(ohlc_data, tlog, dbal, start, end, capital)
        print(dict_to_table(analysis))
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号