Use vn.py2- market recorded

        vnpy very early new version, starting with the python3. After all, it is said that in 2020 python2 come to an end.

        vnpy2 documentation and detailed description are many, many things appear to have good availability, which can be used directly vntrader vnpy simple modification can really use up.

        vn_trader inside is particularly interesting.

        After a turn on this thing, we'll start in the C drive of the user folder below to create a profile, particularly interesting, particularly aspects, will be kept open after each previous configuration files, and delete vnpy, then loaded also still in really a bit like a software of it. Prior to use, in addition to the configuration ctp, remember to click configuration, and then save it, so the C drive profile really began to have the content.

        This is a database in which the above is particularly important, can be configured according to their own situation, mongodb mysql or the like can be.

Backtesting, we need a firm offer before something called the data, first briefly about vnpy provided a recording function called the market right, the picture above is from the left side of the fifth down. After opening the input codes would like to record, may be minute level, it can be tick level. The reason why the configuration database front say, is the software will automatically save the stock market need to record the configuration database.

        For example I minute data distribution requirements and tick data record thread, then:

        db.getCollection('db_tick_data').find({}).sort({"datetime":-1})

        In VnTrader_1Min_Db to find with this statement, you will find the nearest tick is inserted into the database.

 

发布了205 篇原创文章 · 获赞 236 · 访问量 98万+

Guess you like

Origin blog.csdn.net/qtlyx/article/details/100677946