Simulating ETF/index portfolio with BlueShift?

Since ETFs are not available in the datasets (e.g. per minute), does anybody have code that simulates an ETF portfolio? How could you create an indexed portfolio with Blueshift? Are there some data sources that can import the holdings of an index?

This is a bit tricky. If the holdings are constant (no rebalance), then we can beforehand declare the weights (see the buy and hold templates). If the rebalance is based on pure pricing data (price and volume), then we can use the pipeline feature to simulate (see the momentum example in blueshift demo strategies repo).  An example will be a momentum factor ETF. If the stock selection or rebalancing rule is based on anything else, at present it is not possible to simulate.



However, two things up and coming that may change it 1) addition of fundamental data (so all ETFs based on fundamental or fundmanetal + pricing selection criteria will be covered) and 2) addition of ETF data (so you do not have to simulate them and use them directly). The second one will take us more time. First one we expect in a couple of months.