mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-18 02:28:05 +00:00
chore: repo cleanup and code quality improvements
- Remove global.json (SDK pinning unnecessary) - Remove nuget.config, move MyGet source to .csproj RestoreAdditionalProjectSources - Gitignore ndepend/ entirely, move badges to docs/img/ - Update README.md and docs/ndepend.md badge paths - Add NDepend project property to QuanTAlib.slnx - Expand .editorconfig ReSharper/diagnostic suppressions - Use ArgumentOutOfRangeException instead of ArgumentException - Use discard _ for unused event sender parameters - Remove quantalib.code-workspace and sonar-suppressions.json - Add filter signature SVGs
This commit is contained in:
@@ -114,15 +114,11 @@ public sealed class Cointegration : AbstractBase
|
||||
{
|
||||
return Update(new TValue(DateTime.MinValue, seriesA), new TValue(DateTime.MinValue, seriesB), isNew);
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for bi-input indicator. Use Update(seriesA, seriesB) instead.</remarks>
|
||||
public override TValue Update(TValue input, bool isNew = true)
|
||||
{
|
||||
throw new NotSupportedException("Cointegration requires two inputs (seriesA and seriesB). Use Update(seriesA, seriesB).");
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for bi-input indicator. Use Calculate(seriesA, seriesB, period) instead.</remarks>
|
||||
public override TSeries Update(TSeries source)
|
||||
{
|
||||
@@ -402,8 +398,6 @@ public sealed class Cointegration : AbstractBase
|
||||
_sumDelta2 = FusedMultiplyAdd(delta, delta, _sumDelta2);
|
||||
}
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
public override void Prime(ReadOnlySpan<double> source, TimeSpan? step = null)
|
||||
{
|
||||
throw new NotSupportedException("Cointegration requires two inputs.");
|
||||
|
||||
@@ -113,15 +113,11 @@ public sealed class Correlation : AbstractBase
|
||||
{
|
||||
return Update(new TValue(DateTime.MinValue, seriesX), new TValue(DateTime.MinValue, seriesY), isNew);
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for bi-input indicator. Use Update(seriesX, seriesY) instead.</remarks>
|
||||
public override TValue Update(TValue input, bool isNew = true)
|
||||
{
|
||||
throw new NotSupportedException("Correlation requires two inputs (seriesX and seriesY). Use Update(seriesX, seriesY).");
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for bi-input indicator. Use Calculate(seriesX, seriesY, period) instead.</remarks>
|
||||
public override TSeries Update(TSeries source)
|
||||
{
|
||||
@@ -263,8 +259,6 @@ public sealed class Correlation : AbstractBase
|
||||
_sumXY = FusedMultiplyAdd(x, y, _sumXY);
|
||||
}
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
public override void Prime(ReadOnlySpan<double> source, TimeSpan? step = null)
|
||||
{
|
||||
throw new NotSupportedException("Correlation requires two inputs.");
|
||||
|
||||
@@ -108,15 +108,11 @@ public sealed class Granger : AbstractBase
|
||||
{
|
||||
return Update(new TValue(DateTime.UtcNow, seriesY), new TValue(DateTime.UtcNow, seriesX), isNew);
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for dual-input indicator. Use Update(seriesY, seriesX) instead.</remarks>
|
||||
public override TValue Update(TValue input, bool isNew = true)
|
||||
{
|
||||
throw new NotSupportedException("Granger requires two inputs (seriesY and seriesX). Use Update(seriesY, seriesX).");
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for dual-input indicator. Use Batch(seriesY, seriesX, period) instead.</remarks>
|
||||
public override TSeries Update(TSeries source)
|
||||
{
|
||||
@@ -370,8 +366,6 @@ public sealed class Granger : AbstractBase
|
||||
_sumYLagXLag = FusedMultiplyAdd(yLag, xLag, _sumYLagXLag);
|
||||
}
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
public override void Prime(ReadOnlySpan<double> source, TimeSpan? step = null)
|
||||
{
|
||||
throw new NotSupportedException("Granger requires two inputs.");
|
||||
|
||||
@@ -93,15 +93,11 @@ public sealed class Kendall : AbstractBase
|
||||
{
|
||||
return Update(new TValue(DateTime.UtcNow, seriesX), new TValue(DateTime.UtcNow, seriesY), isNew);
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for dual-input indicator. Use Update(seriesX, seriesY) instead.</remarks>
|
||||
public override TValue Update(TValue input, bool isNew = true)
|
||||
{
|
||||
throw new NotSupportedException("Kendall requires two inputs (seriesX and seriesY). Use Update(seriesX, seriesY).");
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for dual-input indicator. Use Batch(seriesX, seriesY, period) instead.</remarks>
|
||||
public override TSeries Update(TSeries source)
|
||||
{
|
||||
@@ -173,8 +169,6 @@ public sealed class Kendall : AbstractBase
|
||||
|
||||
return (concordant - discordant) / denominator;
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
public override void Prime(ReadOnlySpan<double> source, TimeSpan? step = null)
|
||||
{
|
||||
throw new NotSupportedException("Kendall requires two inputs.");
|
||||
|
||||
@@ -279,7 +279,7 @@ public sealed class Pacf : AbstractBase
|
||||
_sum = 0;
|
||||
for (int i = 0; i < _buffer.Count; i++)
|
||||
{
|
||||
_sum += _buffer[i];
|
||||
_sum += _buffer[i];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -98,15 +98,11 @@ public sealed class Spearman : AbstractBase
|
||||
{
|
||||
return Update(new TValue(DateTime.UtcNow, seriesX), new TValue(DateTime.UtcNow, seriesY), isNew);
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for dual-input indicator. Use Update(seriesX, seriesY) instead.</remarks>
|
||||
public override TValue Update(TValue input, bool isNew = true)
|
||||
{
|
||||
throw new NotSupportedException("Spearman requires two inputs (seriesX and seriesY). Use Update(seriesX, seriesY).");
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
/// <remarks>Not supported for dual-input indicator. Use Batch(seriesX, seriesY, period) instead.</remarks>
|
||||
public override TSeries Update(TSeries source)
|
||||
{
|
||||
@@ -236,8 +232,6 @@ public sealed class Spearman : AbstractBase
|
||||
ranks[i] = countSmaller + (countEqual - 1) * 0.5 + 1.0;
|
||||
}
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
public override void Prime(ReadOnlySpan<double> source, TimeSpan? step = null)
|
||||
{
|
||||
throw new NotSupportedException("Spearman requires two inputs.");
|
||||
|
||||
Reference in New Issue
Block a user