braverock / blotter

blotter provides transaction infrastructure for defining transactions, portfolios and accounts for trading systems and simulation. Provides portfolio support for multi-asset class and multi-currency portfolios. Actively maintained and developed.
112 stars 49 forks source link

Fix dates handling in VWAP interval and PWP and exact PWP shares #94

Closed vi-to closed 5 years ago

vi-to commented 5 years ago

This PR builds on #93, which points to #54.

In the VWAP interval case, with respect to trading dates, only a subset of MktData was taken into account. This dates subset may be considered too restrictive and it is indeed reported that the MktData interval that includes trading dates should be referenced to compute this VWAP benchmark price and thus the performance of the trading strategy under it.

With regard to the PWP benchmark, we previously took just enough MktData volume already available to approximate the PWP shares. Now the exact PWP shares are reached. At the same time, both the endpoints remain a proxy.