1
0
mirror of https://github.com/microsoft/qlib.git synced 2026-06-06 05:51:17 +08:00

Merge pull request #441 from zhupr/fix_yahoo_collector

Fix YahooCollector can't download 1min data
This commit is contained in:
you-n-g
2021-05-26 21:41:14 +08:00
committed by GitHub

View File

@@ -581,7 +581,6 @@ class Run(BaseRun):
delay=0,
start=None,
end=None,
interval="1d",
check_data_length=False,
limit_nums=None,
):
@@ -593,8 +592,6 @@ class Run(BaseRun):
default 2
delay: float
time.sleep(delay), default 0
interval: str
freq, value from [1min, 1d], default 1d
start: str
start datetime, default "2000-01-01"
end: str
@@ -611,8 +608,9 @@ class Run(BaseRun):
# get 1m data
$ python collector.py download_data --source_dir ~/.qlib/stock_data/source --region CN --start 2020-11-01 --end 2020-11-10 --delay 0.1 --interval 1m
"""
super(Run, self).download_data(max_collector_count, delay, start, end, interval, check_data_length, limit_nums)
super(Run, self).download_data(
max_collector_count, delay, start, end, self.interval, check_data_length, limit_nums
)
def normalize_data(self, date_field_name: str = "date", symbol_field_name: str = "symbol"):
"""normalize data