Add Ehlers Hilbert Transform Instantaneous Trend (HTIT) implementation and tests

- Implemented the HTIT indicator in Htit.cs, utilizing the Hilbert Transform for trend analysis.
- Added unit tests for HTIT validation against TA-Lib, Skender, and Ooples implementations in Htit.Validation.Tests.cs.
- Created documentation for HTIT in Htit.md, detailing its core concepts, formula, parameters, usage, and interpretation.
This commit is contained in:
Miha Kralj
2025-12-14 16:52:02 -08:00
parent f7b8fe1654
commit 822aaa0d40
18 changed files with 951 additions and 267 deletions
+4 -4
View File
@@ -437,19 +437,19 @@ public class RingBufferTests
}
[Fact]
public void Newest_EmptyBuffer_ReturnsZero()
public void Newest_EmptyBuffer_ReturnsNaN()
{
var buffer = new RingBuffer(5);
Assert.Equal(0, buffer.Newest);
Assert.True(double.IsNaN(buffer.Newest));
}
[Fact]
public void Oldest_EmptyBuffer_ReturnsZero()
public void Oldest_EmptyBuffer_ReturnsNaN()
{
var buffer = new RingBuffer(5);
Assert.Equal(0, buffer.Oldest);
Assert.True(double.IsNaN(buffer.Oldest));
}
[Fact]