squiggle/__tests__/Bandwidth__Test.re

13 lines
313 B
ReasonML
Raw Normal View History

2020-04-03 10:25:42 +00:00
open Jest;
open Expect;
describe("Bandwidth", () => {
2020-04-03 11:08:32 +00:00
test("nrd0()", () => {
2020-04-03 10:25:42 +00:00
let data = [|1., 4., 3., 2.|];
2020-04-03 11:06:05 +00:00
expect(Science.nrd0(data)) |> toEqual(0.7635139420854616);
2020-04-03 10:25:42 +00:00
});
2020-04-03 11:08:32 +00:00
test("nrd()", () => {
2020-04-03 10:25:42 +00:00
let data = [|1., 4., 3., 2.|];
2020-04-03 11:06:05 +00:00
expect(Science.nrd(data)) |> toEqual(0.899249754011766);
2020-04-03 10:25:42 +00:00
});
});