Skip to content

miss numpy package #417

@zhang787jun

Description

@zhang787jun

🐛 Bug Description

qlib/qlib/contrib/backtest/position.py /

161        cash = pd.Series(dtype=np.float)

NameError: name 'np' is not defined

To Reproduce

Steps to reproduce the behavior:

  1. import numpy at head
import numpy as np 

Expected Behavior

Screenshot

Environment

Note: User could run cd scripts && python collect_info.py all under project directory to get system information
and paste them here directly.

  • Qlib version:
  • Python version:
  • OS (Windows, Linux, MacOS):
  • Commit number (optional, please provide it if you are using the dev version):

Additional Notes

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions