mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-18 10:38:05 +00:00
[CodeFactor] Apply fixes to commit 0606491
This commit is contained in:
@@ -61,7 +61,7 @@ public class BbwpIndicatorTests
|
||||
var now = DateTime.UtcNow;
|
||||
for (int i = 0; i < 30; i++)
|
||||
{
|
||||
double basePrice = 100 + i * 2 + (i % 2 == 0 ? 5 : -5); // Add some volatility
|
||||
double basePrice = 100 + (i * 2) + (i % 2 == 0 ? 5 : -5); // Add some volatility
|
||||
indicator.HistoricalData.AddBar(now.AddMinutes(i), basePrice, basePrice + 5, basePrice - 5, basePrice + 2, 1000);
|
||||
|
||||
// Process update for each bar to simulate history loading
|
||||
|
||||
@@ -141,7 +141,7 @@ public class BbwpValidationTests
|
||||
// Feed low volatility data first
|
||||
for (int i = 0; i < 25; i++)
|
||||
{
|
||||
bbwp.Update(new TValue(DateTime.UtcNow.Ticks + i, 100.0 + (i % 2) * 0.1));
|
||||
bbwp.Update(new TValue(DateTime.UtcNow.Ticks + i, 100.0 + ((i % 2) * 0.1)));
|
||||
}
|
||||
|
||||
// Then introduce a high volatility spike
|
||||
|
||||
Reference in New Issue
Block a user