mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-19 19:18:05 +00:00
Atr
This commit is contained in:
@@ -1,25 +0,0 @@
|
||||
using TradingPlatform.BusinessLayer;
|
||||
namespace QuanTAlib;
|
||||
|
||||
public class AmaIndicator : IndicatorBase
|
||||
{
|
||||
[InputParameter("Period", sortIndex: 1, 2, 2000, 1, 0)]
|
||||
public int Period { get; set; } = 10;
|
||||
|
||||
[InputParameter("Alpha", sortIndex: 2, minimum: -0.01, maximum: 1.0, increment: 0.01, decimalPlaces: 2)]
|
||||
public double Alpha { get; set; } = 0.1;
|
||||
private Ama? ma;
|
||||
protected override AbstractBase QuanTAlib => ma!;
|
||||
public override string ShortName => $"AMA {Period} : {Alpha} : {SourceName}";
|
||||
|
||||
|
||||
public AmaIndicator()
|
||||
{
|
||||
Name = "AMA - Adaptive Moving Average";
|
||||
}
|
||||
|
||||
protected override void InitIndicator()
|
||||
{
|
||||
ma = new Ama(period: Period, alpha: Alpha);
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,6 @@
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="System.Drawing.Common" Version="8.0.0" />
|
||||
<PackageReference Include="Microsoft.DotNet.Interactive.Formatting" Version="1.0.0-beta.21459.1" />
|
||||
<Compile Include="..\..\lib\**\*.cs" Exclude="..\..\lib\obj\**">
|
||||
<Link>lib\%(RecursiveDir)%(Filename)%(Extension)</Link>
|
||||
</Compile>
|
||||
|
||||
Reference in New Issue
Block a user