- Accounts & Connection Management
- Data Management & Analysis
- Price Monitoring
- Charting
- Trading
- Scanners
-
Builders
-
Manual Strategy Builder
- Main Concept
- Operand Component
- Algo Elements
-
Use Cases
- How to create a condition on something crossing something
- How to create an indicator based on another indicator
- How to calculate a stop loss based on indicator
- How to submit stop order based on calculated price
- How to calculate a current bar price using a price type from inputs
- How to Use a Closed Bar Price
- Automatic Strategy Builder
-
Manual Strategy Builder
- Autotrading
- FinScript
- Trade Analysis
- Media Feeds
- Logs & Notifications
- UI & UX
To create a new BarsType a developer should create couple of classes:
- First class should be inherited from GeneratedBarsPeriod class. This class defines different parameters for bars creation, for example Period, Size etc. Once class is created a developer must override a property Name to set a name for period.
public class TestBarsTypePeriod : GeneratedBarsPeriod
{
[Display(GroupName = nameof(Resource.ScriptDataSeries), Name = nameof(Resource.BarsPeriodTypeNameRange), Order = 2, ResourceType = typeof(Resource))]
[Range(1, int.MaxValue)]
public int TestRange { get; set; } = 2;
protected override string Name => "Test Bars type";
}
- Second class should be inherited from GeneratedBarsType<T> class where T is a BarsPeriod class created on the first step. This class defines rules for bars creation. Once class is created a developer must override a method CreateBuilder in which a developer should implement logic of bars building.
internal class TestBarsType:GeneratedBarsType<TestBarsTypePeriod>
{
#region Overrides of BarsTypeBase
/// <inheritdoc />
public override BarsBuilder CreateBuilder(IBarStorage barStorage, TradingHours? tradingHours = null)
{
//Write your code here
}
#endregion
}
Once new BarsType is developed one can use it on a chart.
- Accounts & Connection Management
- Data Management & Analysis
- Price Monitoring
- Charting
- Trading
- Scanners
-
Builders
-
Manual Strategy Builder
- Main Concept
- Operand Component
- Algo Elements
-
Use Cases
- How to create a condition on something crossing something
- How to create an indicator based on another indicator
- How to calculate a stop loss based on indicator
- How to submit stop order based on calculated price
- How to calculate a current bar price using a price type from inputs
- How to Use a Closed Bar Price
- Automatic Strategy Builder
-
Manual Strategy Builder
- Autotrading
- FinScript
- Trade Analysis
- Media Feeds
- Logs & Notifications
- UI & UX