Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Backtest ¶
type Backtest struct { ID string `json:"id"` Strategy string `json:"strategy"` ExecutionType string `json:"execution_type"` Config BacktestConfig `json:"config"` WorkerParameters []WorkerParameter `json:"worker_parameters"` Stage string `json:"stage"` Error string `json:"error"` Socket socket.Socket `json:"socket"` }
type BacktestConfig ¶
type BacktestStorage ¶
type BacktestStorage interface { List(context.Context, string) ([]*Backtest, error) ListByStage(context.Context, ...string) ([]*Backtest, error) Create(context.Context, string, *Backtest) error Get(context.Context, string) (*Backtest, error) Update(context.Context, *Backtest) error Delete(context.Context, string) error }
type Period ¶
type Period struct { ID int `json:"-"` Period time.Time `json:"period" mapstructure:"period"` ShortsCount int `json:"shorts_count" mapstructure:"shorts_count"` PNL float64 `json:"pnl" mapstructure:"pnl"` LongValue float64 `json:"long_value" mapstructure:"long_value"` ShortValue float64 `json:"short_value" mapstructure:"short_value"` LongExposure float64 `json:"long_exposure" mapstructure:"long_exposure"` StartingExposure float64 `json:"starting_exposure" mapstructure:"starting_exposure"` ShortExposure float64 `json:"short_exposure" mapstructure:"short_exposure"` CapitalUsed float64 `json:"capital_used" mapstructure:"capital_used"` GrossLeverage float64 `json:"gross_leverage" mapstructure:"gross_leverage"` NetLeverage float64 `json:"net_leverage" mapstructure:"net_leverage"` EndingExposure float64 `json:"ending_exposure" mapstructure:"ending_exposure"` StartingValue float64 `json:"starting_value" mapstructure:"starting_value"` EndingValue float64 `json:"ending_value" mapstructure:"ending_value"` StartingCash float64 `json:"starting_cash" mapstructure:"starting_cash"` EndingCash float64 `json:"ending_cash" mapstructure:"ending_cash"` Returns float64 `json:"returns" mapstructure:"returns"` PortfolioValue float64 `json:"portfolio_value" mapstructure:"portfolio_value"` LongsCount int `json:"longs_count" mapstructure:"longs_count"` AlgoVolatility float64 `json:"algo_volatility" mapstructure:"algo_volatility"` Sharpe float64 `json:"sharpe" mapstructure:"sharpe"` Alpha float64 `json:"alpha" mapstructure:"alpha"` Beta float64 `json:"beta" mapstructure:"beta"` Sortino float64 `json:"sortino" mapstructure:"sortino"` MaxDrawdown float64 `json:"max_drawdown" mapstructure:"max_drawdown"` MaxLeverage float64 `json:"max_leverage" mapstructure:"max_leverage"` ExcessReturns float64 `json:"excess_returns" mapstructure:"excess_returns"` TreasuryPeriodReturn float64 `json:"treasure_period_return" mapstructure:"treasure_period_return"` TradingDays int `json:"trading_days" mapstructure:"trading_days"` BenchmarkPeriodReturns float64 `json:"benchmark_period_returns" mapstructure:"benchmark_period_returns"` BenchmarkVolatility float64 `json:"benchmark_volatility" mapstructure:"benchmark_volatility"` AlgorithmPeriodReturns float64 `json:"algorithm_period_return" mapstructure:"algorithm_period_return"` }
type PeriodStorage ¶
type StrategyStorage ¶
type WorkerParameter ¶
Click to show internal directories.
Click to hide internal directories.