Refactor code formatting and improve consistency across various test files

- Removed unnecessary blank lines in multiple test files to enhance readability.
- Ensured consistent spacing and formatting in the `Trima`, `Usf`, `Vidya`, `Wma`, and `Atr` test classes.
- Updated comments for clarity and consistency in the `Atr` and `Adl` classes.
- Adjusted project files for better structure and maintainability.
This commit is contained in:
Miha Kralj
2025-12-28 17:44:08 -08:00
parent ad6eebf812
commit 13d7c1215d
169 changed files with 10815 additions and 10814 deletions
+2 -2
View File
@@ -170,7 +170,7 @@ public sealed class AtrValidationTests : IDisposable
var atrIndicator = Tulip.Indicators.atr;
double[][] inputs = { hData, lData, cData };
double[] options = { period };
// Tulip ATR lookback
int lookback = atrIndicator.Start(options);
double[][] outputs = { new double[hData.Length - lookback] };
@@ -208,7 +208,7 @@ public sealed class AtrValidationTests : IDisposable
var atrIndicator = Tulip.Indicators.atr;
double[][] inputs = { hData, lData, cData };
double[] options = { period };
// Tulip ATR lookback
int lookback = atrIndicator.Start(options);
double[][] outputs = { new double[hData.Length - lookback] };
+4 -4
View File
@@ -59,8 +59,8 @@ public sealed class Atr : AbstractBase
var tr = CalculateTrueRange(source);
_rma.Prime(tr.Values);
Last = _rma.Last;
// We can't automatically subscribe to TBarSeries updates via this constructor
// because AbstractBase doesn't enforce TBarSeries subscription structure,
// We can't automatically subscribe to TBarSeries updates via this constructor
// because AbstractBase doesn't enforce TBarSeries subscription structure,
// but we can rely on manual updates or the user subscribing.
}
@@ -73,8 +73,8 @@ public sealed class Atr : AbstractBase
/// <summary>
/// Initializes the indicator state using the provided history.
/// Note: ATR needs OHLCV data to calculate TR properly.
/// This Prime method expects pre-calculated TR values or handles basic priming
/// Note: ATR needs OHLCV data to calculate TR properly.
/// This Prime method expects pre-calculated TR values or handles basic priming
/// if the user erroneously passes non-TR data. Ideally, use Batched TBarSeries.
/// </summary>
public override void Prime(ReadOnlySpan<double> source, TimeSpan? step = null)