Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backtest strategy with only one asset and positions #9

Closed
MislavSag opened this issue Sep 15, 2020 · 2 comments
Closed

Backtest strategy with only one asset and positions #9

MislavSag opened this issue Sep 15, 2020 · 2 comments

Comments

@MislavSag
Copy link

Finally there is some activity on backtesting in R community :) There are multiplie options in python but not so many in R.

I am aware your package is more about portfloio backtesting, but I am curious is there a simple way to backtetst strategy in which I hold / not hold one asset (0 and 1 without short selling). So I have a vector of prices on 1 minute basis and I know dates on which I hold the position. I would need the performance, expecialy relative performance (relative to banschmark).

@dppalomar
Copy link
Owner

@MislavSag, thanks for your comments.

It is no problem if your xts data only has one column (one asset to invest). Apart from that, you are referring to two other currently open issues:

  • Issue Allow for different rebalancing schedules #4: to allow setting positions on specific dates. We plan to implement this, but I don't know when.
  • Issue Allow different data frequencies apart from daily #8: to allow different frequencies apart from daily. The current code should run without errors with a different frequency (like 1-min), but for sure there will be some wrong computations of the performance measures (probably some factors that are different for 1-min than daily). This one we also want to implement and it should be easy, but I don't know when.

@dppalomar
Copy link
Owner

Issue #8 has been implemented to allow for higher frequencies than daily.
Issue #4 not yet.
I close this issue since it is #4 that remains to be implemented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants