mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-15 00:58:04 +00:00
cleanup
This commit is contained in:
@@ -33,7 +33,6 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="xunit" Version="2.4.1" />
|
||||
<ProjectReference Include="..\lib\quantalib.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
@@ -13,10 +13,9 @@ public class SkenderTests
|
||||
private readonly Random rnd;
|
||||
private readonly double range;
|
||||
private int period;
|
||||
private readonly int iterations;
|
||||
private readonly int iterations = 3; // Initialized directly at declaration
|
||||
private readonly IEnumerable<Quote> quotes;
|
||||
|
||||
|
||||
public SkenderTests()
|
||||
{
|
||||
rnd = new((int)DateTime.Now.Ticks);
|
||||
@@ -24,7 +23,6 @@ public class SkenderTests
|
||||
bars = new(feed);
|
||||
range = 1e-9;
|
||||
feed.Add(10000);
|
||||
iterations = 3;
|
||||
quotes = bars.Select(q => new Quote
|
||||
{
|
||||
Date = q.Time,
|
||||
@@ -338,15 +336,11 @@ public class SkenderTests
|
||||
var atrValues = quotes.GetAtr(lookbackPeriods: period).Select(i => i.Atr.Null2NaN()!);
|
||||
const int AdditionalPeriods = 500;
|
||||
|
||||
<<<<<<< HEAD
|
||||
for (int i = QL.Length - 1; i > period + 500; i--)
|
||||
=======
|
||||
for (int i = QL.Length - 1; i > period + AdditionalPeriods; i--)
|
||||
>>>>>>> dev
|
||||
{
|
||||
Assert.InRange(atrValues.ElementAt(i) - QL[i].Value, -range, range);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user