man-group / arctic

High performance datastore for time series and tick data
https://arctic.readthedocs.io/en/latest/
GNU Lesser General Public License v2.1
3.05k stars 583 forks source link

VersionStore slicing doesn't seem work. #863

Closed zechzhao closed 2 years ago

zechzhao commented 4 years ago

Arctic Version

latest version ( downloaded yesterday)

Arctic Store

VersionStore

Platform and version

Ubuntu 19.10
MongoDB shell version v3.6.8
Python 3.7.5

Description of problem and/or code sample that reproduces the issue

The database works for me just as the quickstart example. However, when attempt the library, read slicing options, it seems does not work: as long slicing options are enabled, whether column or dateRange, the data returned is a wrong DataFrame. e.g.

item = library.read('test', colums='high' ).data returns the full table instead of pandas.Series test.high item = library.read('test', date_range=DateRange(pd.to_datetime('2016-01-02'), pd.to_datetime('2016-02-03'))).data returns an empty DataFrame.

The index of dataFrame used to write to the database and read from the database with simply library.read('test').data are both of the type pandas.timestamps (datetime64).

Upon checking the source: the daterange in put can be int, str or datetime.datetime, all of them were attempted however, none of them worked.

Not sure if there is anything else that I have missed before slicing can finally work.

Thanks

bmoscon commented 4 years ago

versionstore doesnt support reading out specific columns (what you are calling slicing)

zechzhao commented 4 years ago

Thanks for the clarification. Any suggestions on what could I check on reading out data with in a period? thanks

jasonlocal commented 2 years ago

The best practice is to use ChunkStore fro reading out data for a specific period. I am going to close the issue, but please feel free to reopen if this is still an issue

jasonlocal commented 2 years ago

closed legacy issue