Add support for fetching range of dates
This commit is contained in:
8
src/utils/index.ts
Normal file
8
src/utils/index.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
export const sleep = (ms: number) => new Promise(resolve => setTimeout(resolve, ms));
|
||||
|
||||
export const gaussianRandom = (mean = 0, stddev = 1) => {
|
||||
let u1 = Math.random();
|
||||
let u2 = Math.random();
|
||||
let z0 = Math.sqrt(-2.0 * Math.log(u1)) * Math.cos(2.0 * Math.PI * u2);
|
||||
return z0 * stddev + mean;
|
||||
}
|
||||
Reference in New Issue
Block a user