Signal Exports
Collective2
Introduction
Collective2 is a service that connects strategy developers and capital allocators. With our Collective2 integration, you can send trading signals from your live algorithms to Collective2.
Add Providers
To export signals to Collective2 from your algorithm, during initialization, add a Collective2 signal export provider.
SignalExport.AddSignalExportProviders(new Collective2SignalExport(apiKey, systemId));
self.signal_export.add_signal_export_providers(Collective2SignalExport(apiKey, systemId))
The Collective2SignalExport
constructor accepts the following arguments:
Argument: |
Argument: |
You can add multiple signal export providers to a single algorithm.
Send Portfolio Targets
To send targets to Collective2, pass a PortfolioTarget
object or an arraya list of PortfolioTarget
objects to the SetTargetPortfolio
set_target_portfolio
method. The method returns a boolean that represents if the targets were successfully sent to Collective2. In this situation, the number you pass to the PortfolioTarget
constructor represents the portfolio weight. Don't use the PortfolioTarget.Percent
PortfolioTarget.percent
method.
var target = new PortfolioTarget(_symbol, weight); var success = SignalExport.SetTargetPortfolio(target);
target = PortfolioTarget(self._symbol, weight) success = self.signal_export.set_target_portfolio(target)
If you use a margin account, you can send your current portfolio holdings by calling the SetTargetPortfolioFromPortfolio
set_target_portfolio_from_portfolio
method.
var success = SignalExport.SetTargetPortfolioFromPortfolio();
success = self.signal_export.set_target_portfolio_from_portfolio()