Skip to content

Commit

Permalink
0.9.59 fix dt type error
Browse files Browse the repository at this point in the history
  • Loading branch information
zengbin93 committed Sep 2, 2024
1 parent 3b0f826 commit 5bccbb6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions czsc/traders/weight_backtest.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,7 @@ def __init__(self, dfw, digits=2, **kwargs) -> None:
"""
self.kwargs = kwargs
self.dfw = dfw.copy()
self.dfw["dt"] = pd.to_datetime(self.dfw["dt"])
if self.dfw.isnull().sum().sum() > 0:
raise ValueError("dfw 中存在空值, 请先处理")
self.digits = digits
Expand Down

0 comments on commit 5bccbb6

Please sign in to comment.