Show / Hide Table of Contents

Class DataSource

Helper class to load asset data from various data feeds.

Inheritance
object
DataSource
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: TuringTrader.SimulatorV2
Assembly: TuringTrader.Simulator.dll
Syntax
public static class DataSource

Fields

| Improve this Doc View Source

_lockNorgate

Object to block reentrance into Norgate APIs. This object is made public to interface between code of v1 and v2 engine. DO NOT TOUCH!

Declaration
public static object _lockNorgate
Field Value
Type Description
object

Methods

| Improve this Doc View Source

CustomGetAsset(Algorithm, string, Func<List<BarType<OHLCV>>>)

Declaration
public static TimeSeriesAsset CustomGetAsset(Algorithm owner, string nickname, Func<List<BarType<OHLCV>>> retrieve)
Parameters
Type Name Description
Algorithm owner
string nickname
System.Func<TResult><System.Collections.Generic.List<T><BarType<OHLCV>>> retrieve
Returns
Type Description
TimeSeriesAsset
| Improve this Doc View Source

LoadAsset(Algorithm, string)

Load asset data from various data feeds.

Declaration
public static TimeSeriesAsset LoadAsset(Algorithm owner, string nickname)
Parameters
Type Name Description
Algorithm owner

parent/ owning algorithm

string nickname

asset nickname

Returns
Type Description
TimeSeriesAsset

time series for asset

Exceptions
Type Condition
System.Exception
| Improve this Doc View Source

LoadAsset(Algorithm, IAlgorithm)

Load result from child algorithm as an asset.

Declaration
public static TimeSeriesAsset LoadAsset(Algorithm owner, IAlgorithm generator)
Parameters
Type Name Description
Algorithm owner

parent/ owning algorithm

IAlgorithm generator

child/ generating algorithm

Returns
Type Description
TimeSeriesAsset
| Improve this Doc View Source

StaticGetUniverse(Algorithm, string, string)

Return static universe. The constituents for these universes are time-invariant, hence suffering from survivorship bias.

Declaration
public static HashSet<string> StaticGetUniverse(Algorithm algo, string universe, string datafeed)
Parameters
Type Name Description
Algorithm algo

parent algorithm

string universe

universe name

string datafeed

datafeed name

Returns
Type Description
System.Collections.Generic.HashSet<T><string>

universe constituents

Exceptions
Type Condition
System.Exception
| Improve this Doc View Source

Universe(Algorithm, string)

Get constituents of universe.

Declaration
public static HashSet<string> Universe(Algorithm algo, string name)
Parameters
Type Name Description
Algorithm algo

parent algorithm

string name

universe name

Returns
Type Description
System.Collections.Generic.HashSet<T><string>

universe constituents

  • Improve this Doc
  • View Source
In This Article
Back to top Copyright © 2011-2023, Bertram Enterprises LLC dba TuringTrader.com