14 Commits

Author SHA1 Message Date
Adalyat Nazirov 1e3a1e3c43 Historical data requests start & time fix (#4733)
* regression tests

* fix: apply the same time convertion to history request time as for data time

* ver2

* fixup

* unit tests

* do not need this conversion because RoundDownInTimeZone returns in proper TZ

* comment

* requested changes

* refactoring

* more refactoring

* fix existing test: should return Sunday if open

* more symbols

* fix existing tests: submit new btcusd data

* fix

* add Cfd symbol
2020-09-24 14:51:35 -03:00
Martin Molinero bcc67d2457 DataPermissionManager is used by history provider
- DataPermissionManager will be used by the history provider
- Moving interfaces from Engine to Common
2020-06-12 12:51:14 -03:00
Martin Molinero 87bc03d71e Address reviews
- When BacktestNodePacket has the inital `CashAmount` set we will clear
all existing cash amounts and set the account currency
- Adding more unit tests
2019-12-31 13:25:58 -03:00
Martin Molinero eb9fe73ebc Engine code clean up 2019-08-16 19:09:45 -03:00
Jared fc1b5bda61 Merge pull request #3507 from IlshatGaripov/base-setup-handler-remove-always-false-cond
Removes always false condition checking in BaseSetupHandler
2019-08-14 15:53:29 -07:00
IlshatGaripov 5ff0d60697 Cleans always false conditions checking ? 2019-08-14 14:01:13 +03:00
Martin Molinero f887c42638 Enable python and CSharp debugging
- Adding `DebuggerHelper` class, handles debugging initialization
- Setting the "PYTHONPATH" will be handled by the `JobQueue`
2019-08-12 22:03:13 -03:00
Martin Molinero 0d6d66cd09 SPY default security benchmark
- Setting SPY as the default security benchmark
- The security benchmark subscription will be added at `UniverseSelection`
as an internal subscription. Using its own dedicated Security instance
which doesn't live in the algorithms.Securities collection.
- Reducing algorithms exposure to internal subscriptions
- `TimeSliceFactory` will prioritize higher resolution bars, when same
symbol is present twice (for non-internal subscriptionst)
- Adding regression test `CustomUniverseWithBenchmarkRegressionAlgorithm`
2019-08-06 21:15:33 -03:00
Martin Molinero 1b0bdd9b0b Adding SetAccountCurrency for backtesting
- Adding new `SetAccountCurrency()` for backtesting. Has to be called
before adding any `Security` or calling `SetCash()`, else will throw.
- Adding new Non account currency unit tests for `CashBuyingPower`,
`SecurityPortfolioModel`, `SecurityMarginModel`,
`SecurityPortfolioManager`, `Future/OptionMarginBuyingPowerModels`
- Adding new C# regression test using `SetAccountCurrency()`, one for
`CashBuyingPowerModel` and one for `SecurityMarginModel`
- Adding new Py and C# basic regression algorithms using
`SetAccountCurrency()`
- `Options` and `Futures` will use not use `AccountCurrency` as quote
Cash.
- `SecurityBenchmark` value will be in account currency
2019-01-25 14:54:43 -03:00
Martin Molinero 3717fe4651 IB FeeModel will be based on Market
- The `InteractiveBrokersFeeModel` will determine commissions based on
the `Market` of the security
2019-01-02 14:10:32 -03:00
Martin Molinero 8e41371e19 Non-Usd brokerage support
- `GetCashBalance()` will return a `List<CashAmount>`, will not need to
set conversion rates, which requires knowing what the account currency is.
- Removing `Global.Holding` conversion rate field. It wasn't being used
and required knowing what the account currency is.
- Adding equality operators for `CashAmount`. Adding unit tests.
2018-12-27 12:13:43 -03:00
Martin Molinero 9a2bc5c33e Fix undeterministic conversion rates
- `BaseSetupHandler.SetupCurrencyConversions` will order configurations
based on their type, selecting (`Trade` over `Quote`) and just perform
one history request per security.
2018-12-24 17:03:02 -03:00
Martin Molinero 65ea963a26 Using new HistoryRequestFactory
- BaseSetupHandler will use new `HistoryRequestProvider` class
2018-12-19 16:15:29 -03:00
Martin Molinero a26b3542bb Address reviews
- `ISetupHandler.Setup()` will now receive a parameters object
- Removing `SetupHandlerHelper` and adding new `BaseSetupHandler`
2018-12-19 16:15:28 -03:00