Beispiel #1
0
        public async Task TestBbWidthAsync()
        {
            var candles = await ImportCandlesAsync();

            var indicator = new BollingerBandWidth(candles, 20, 2);
            var result    = indicator[candles.Count - 1];

            Assert.IsTrue(5.165m.IsApproximatelyEquals(result.Value));
        }
Beispiel #2
0
        public async Task TestBbWidthAsync()
        {
            var equity = await ImportEquityAsync();

            var indicator = new BollingerBandWidth(equity, 20, 2);
            var result    = indicator.ComputeByIndex(equity.Count - 1);

            Assert.IsTrue(5.165m.IsApproximatelyEquals(result.BandWidth.Value));
        }