mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-18 02:28:05 +00:00
Remove multiple Pine Script indicators: SSFDSP, STARCHANNEL, STBANDS, STC, UBANDS, UCHANNEL, VWAPBANDS, and VWAPSD. These indicators were deleted to streamline the library and remove unused or redundant code.
This commit is contained in:
@@ -530,18 +530,10 @@ public class RviTests
|
||||
public void Batch_LargeDataset_NoStackOverflow()
|
||||
{
|
||||
const int dataLen = 10000;
|
||||
double[] prices = new double[dataLen];
|
||||
var bars = new GBM(seed: 42).Fetch(dataLen, DateTime.UtcNow.Ticks, TimeSpan.FromMinutes(1));
|
||||
double[] prices = bars.CloseValues.ToArray();
|
||||
double[] output = new double[dataLen];
|
||||
|
||||
// Fill with realistic data
|
||||
double price = 100.0;
|
||||
var rng = new Random(42);
|
||||
for (int i = 0; i < dataLen; i++)
|
||||
{
|
||||
price *= 1.0 + (rng.NextDouble() - 0.5) * 0.02;
|
||||
prices[i] = price;
|
||||
}
|
||||
|
||||
Rvi.Batch(prices, output, stdevLength: 10, rmaLength: 14);
|
||||
|
||||
// Verify all outputs are valid
|
||||
|
||||
@@ -453,27 +453,12 @@ public class TrTests
|
||||
public void Batch_LargeDataset_NoStackOverflow()
|
||||
{
|
||||
const int dataLen = 10000;
|
||||
double[] highs = new double[dataLen];
|
||||
double[] lows = new double[dataLen];
|
||||
double[] closes = new double[dataLen];
|
||||
var bars = new GBM(seed: 42).Fetch(dataLen, DateTime.UtcNow.Ticks, TimeSpan.FromMinutes(1));
|
||||
double[] highs = bars.HighValues.ToArray();
|
||||
double[] lows = bars.LowValues.ToArray();
|
||||
double[] closes = bars.CloseValues.ToArray();
|
||||
double[] output = new double[dataLen];
|
||||
|
||||
// Fill with realistic data
|
||||
double price = 100.0;
|
||||
var rng = new Random(42);
|
||||
for (int i = 0; i < dataLen; i++)
|
||||
{
|
||||
double volatility = 0.02;
|
||||
double high = price * (1 + rng.NextDouble() * volatility);
|
||||
double low = price * (1 - rng.NextDouble() * volatility);
|
||||
double close = low + rng.NextDouble() * (high - low);
|
||||
|
||||
highs[i] = high;
|
||||
lows[i] = low;
|
||||
closes[i] = close;
|
||||
price = close;
|
||||
}
|
||||
|
||||
Tr.Batch(highs, lows, closes, output);
|
||||
|
||||
// Verify all outputs are valid
|
||||
|
||||
@@ -487,19 +487,10 @@ public class UiTests
|
||||
public void Batch_LargeDataset_NoStackOverflow()
|
||||
{
|
||||
const int dataLen = 10000;
|
||||
double[] source = new double[dataLen];
|
||||
var bars = new GBM(seed: 42).Fetch(dataLen, DateTime.UtcNow.Ticks, TimeSpan.FromMinutes(1));
|
||||
double[] source = bars.CloseValues.ToArray();
|
||||
double[] output = new double[dataLen];
|
||||
|
||||
// Fill with realistic data
|
||||
double price = 100.0;
|
||||
var rng = new Random(42);
|
||||
for (int i = 0; i < dataLen; i++)
|
||||
{
|
||||
double change = (rng.NextDouble() - 0.5) * 2; // -1% to +1%
|
||||
price *= (1 + change / 100);
|
||||
source[i] = price;
|
||||
}
|
||||
|
||||
Ui.Batch(source, output, DefaultPeriod);
|
||||
|
||||
// Verify all outputs are valid
|
||||
|
||||
@@ -614,19 +614,10 @@ public class VovTests
|
||||
public void Batch_LargeDataset_NoStackOverflow()
|
||||
{
|
||||
const int dataLen = 10000;
|
||||
double[] source = new double[dataLen];
|
||||
var bars = new GBM(seed: 42).Fetch(dataLen, DateTime.UtcNow.Ticks, TimeSpan.FromMinutes(1));
|
||||
double[] source = bars.CloseValues.ToArray();
|
||||
double[] output = new double[dataLen];
|
||||
|
||||
// Fill with realistic data
|
||||
double price = 100.0;
|
||||
var rng = new Random(42);
|
||||
for (int i = 0; i < dataLen; i++)
|
||||
{
|
||||
double change = (rng.NextDouble() - 0.5) * 2; // -1% to +1%
|
||||
price *= (1 + change / 100);
|
||||
source[i] = price;
|
||||
}
|
||||
|
||||
Vov.Batch(source, output, DefaultVolatilityPeriod, DefaultVovPeriod);
|
||||
|
||||
// Verify all outputs are valid
|
||||
|
||||
Reference in New Issue
Block a user