microsoft/qlib

Cannot get actual price from qlib data.

langslike opened this issue · 0 comments

Yes, I read the docs about adjusted price data and how to dump my own csv to bins. But the problem is, the price I got in qlib is far diferent from actual price:

for stock SH600519, use code below:
qdl = QlibDataLoader(config=(['$close', '$high'],['close', 'high']))
qdl.load(instruments=['SH600519'], start_time='20200101', end_time='20201231')
the result is :

<style scoped> .dataframe tbody tr th:only-of-type { vertical-align: middle; }
.dataframe tbody tr th {
    vertical-align: top;
}

.dataframe thead th {
    text-align: right;
}
</style>
close high
datetime instrument
2020-01-02 SH600519 237.950500 241.121780
2020-01-03 SH600519 227.118515 235.213028
2020-01-06 SH600519 226.998474 230.138153
2020-01-07 SH600519 230.481384 231.422653
2020-01-08 SH600519 229.135818 229.135818
... ... ... ...
2020-09-21 SH600519 355.087494 360.617889
2020-09-22 SH600519 354.850983 359.386536
2020-09-23 SH600519 351.504211 354.919189
2020-09-24 SH600519 347.102905 353.400238
2020-09-25 SH600519 348.336365 351.508484

180 rows × 2 columns

but the post-adjustd price data from choice database is:
image

Yes, I know the price in qlib and the actual price they are pertty similar: I only need to apply a value resize to make the equal. But if I update the qlib data with my own csv actual backward adjusted data, will qlib remember to do the reverse resize to keep the price series consistent?