mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-17 01:58:06 +00:00
[CodeFactor] Apply fixes to commit 4a01f03
This commit is contained in:
@@ -440,9 +440,9 @@ public sealed class Dwt : AbstractBase
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
static double Get(Span<double> b, int h, int c, int lag)
|
||||
{
|
||||
int idx = ((h - 1 - lag) % c + c) % c;
|
||||
int idx = (((h - 1 - lag) % c) + c) % c;
|
||||
int maxLag = c - 1;
|
||||
if (lag > maxLag) { idx = ((h - 1 - maxLag) % c + c) % c; }
|
||||
if (lag > maxLag) { idx = (((h - 1 - maxLag) % c) + c) % c; }
|
||||
return b[idx];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user