import { EastFunction, RandomKeyFunction, RandomNormalFunction, RandomRangeFunction, RandomUniformFunction, RandomValueFunction, RandomWeightedKeyFunction } from '../functions'; import { ArrayType, DictType, FloatType, IntegerType, SetType, StringType } from '../types'; import { Expression } from './core'; /** * Return a random float greater or equal to `0.0` and less than `1.0`. * * @category Expression * * @example * ```typescript * // ... * // create a random float between zero and one * x: RandomUniform(), * // ... * ``` */ export declare function RandomUniform(): RandomUniformFunction; /** * Return a random float greater or equal to `min` and less than `max`. * * @category Expression * * @example * ```typescript * // ... * // create a random float between 1.0 and 10.0 * x: RandomUniform(1.0, 10.0), * // ... * ``` */ export declare function RandomUniform(min: EastFunction | number, max: EastFunction | number): EastFunction; /** * Return a random float drawn from a normal (Gaussian) distribution with mean `0.0` and standard deviation `1.0`. * * @category Expression * * @example * ```typescript * // ... * // create a random float from a normal distribution * x: RandomNormal(), * // ... * ``` */ export declare function RandomNormal(): RandomNormalFunction; /** * Return a random integer between `min` and `max` (inclusive). * * @param min the {@link Expression} for the minimum value to return * @param max the {@link Expression} for the maximum value to return * * @category Expression * * @example * ```typescript * // ... * // create a random integer between zero and one * x: RandomRange(0n, 10n), * // ... * ``` */ export declare function RandomRange(min: bigint | EastFunction, max: bigint | EastFunction): RandomRangeFunction; /** * Return a random value drawn from an array or dictionary. * * @param collection the {@link EastFunction} for collection to sample values from * @param def an optional {@link Expression} for the default value to return if the collection is empty * * @category Expression * * @example * ```typescript * // ... * // draw a random string "a", "b" or "c" * x: RandomValue(Const(["a", "b", "c"])), * // ... * ``` */ export declare function RandomValue(collection: EastFunction, def?: Expression): RandomValueFunction; export declare function RandomValue(collection: EastFunction, def?: Expression): RandomValueFunction; /** * Return a random key drawn from an array, dictionary or set. * * @param collection the {@link EastFunction} for collection to sample keys from * @param def an optional {@link Expression} for the default value to return if the collection is empty * * @category Expression * * @example * ```typescript * // ... * // draw a random string "a", "b" or "c" * x: RandomKey(Const(new Set(["a", "b", "c"]))), * // ... * ``` */ export declare function RandomKey(collection: EastFunction, def?: Expression): RandomKeyFunction; export declare function RandomKey(collection: EastFunction, def?: Expression): RandomKeyFunction; export declare function RandomKey(collection: EastFunction, def?: Expression): RandomKeyFunction; /** * Return a random key drawn from an array or dictionary with non-negative float values representing the relative probability of different keys. * * @param collection the {@link EastFunction} for collection to sample keys from * @param def an optional {@link Expression} for the default value to return if the collection is empty * * @category Expression * * @example * ```typescript * // ... * // draw a random string "a", "b" or "c" * x: RandomKey(Const(new Set(["a", "b", "c"]))), * // ... * ``` */ export declare function RandomWeightedKey>(collection: EastFunction, def?: Expression): RandomWeightedKeyFunction; export declare function RandomWeightedKey>(collection: EastFunction, def?: Expression): RandomWeightedKeyFunction;