{{alias}}( shape, lambda[, options] ) Generates pseudorandom numbers drawn from an exponential distribution. Parameters ---------- shape: Array Array shape. lambda: number Rate parameter. options: Object (optional) Options. options.dtype: string (optional) Output array data type. Default: 'float64'. options.order: string (optional) Specifies whether an array is row-major (C-style) or column-major (Fortran-style). Default: 'row-major'. options.mode: string (optional) Specifies how to handle indices which exceed array dimensions. If equal to 'throw', an ndarray instance throws an error when an index exceeds array dimensions. If equal to 'wrap', an ndarray instance wraps around indices exceeding array dimensions using modulo arithmetic. If equal to 'clamp', an ndarray instance sets an index exceeding array dimensions to either `0` (minimum index) or the maximum index. Default: 'throw'. options.submode: Array (optional) Specifies how to handle subscripts which exceed array dimensions. If a mode for a corresponding dimension is equal to 'throw', an ndarray instance throws an error when a subscript exceeds array dimensions. If equal to 'wrap', an ndarray instance wraps around subscripts exceeding array dimensions using modulo arithmetic. If equal to 'clamp', an ndarray instance sets a subscript exceeding array dimensions to either `0` (minimum index) or the maximum index. If the number of modes is less than the number of dimensions, an ndarray instance recycles modes using modulo arithmetic. Default: [ options.mode ]. options.readonly: boolean (optional) Boolean indicating whether an array should be read-only. Default: false. Returns ------- out: ndarray Output array. Examples -------- > var out = {{alias}}( [ 3, 3 ], 2.0 ) {{alias}}.assign( out, lambda ) Fills an ndarray with pseudorandom numbers drawn from an exponential distribution. Parameters ---------- out: ndarray Output ndarray. lambda: number Rate parameter. Returns ------- out: ndarray Output array. Examples -------- > var arr = {{alias:@stdlib/ndarray/zeros}}( [ 3, 3 ] ); > var out = {{alias}}.assign( arr, 2.0 ) > var bool = ( out === arr ) true {{alias}}.factory( [options] ) Returns a function for generating pseudorandom numbers drawn from an exponential distribution. The returned function accepts the following options, each of which overrides the respective default: - dtype: output array data type. - order: memory layout (either row-major or column-major). - mode: specifies how to handle indices which exceed array dimensions. - submode: specifies how to handle subscripts which exceed array dimensions on a per dimension basis. - readonly: boolean indicating whether an array should be read-only. Parameters ---------- options: Object (optional) Options. options.prng: Function (optional) Pseudorandom number generator (PRNG) for generating uniformly distributed pseudorandom numbers on the interval `[0,1)`. If provided, the `state` and `seed` options are ignored. In order to seed the returned pseudorandom number generator, one must seed the provided `prng` (assuming the provided `prng` is seedable). options.seed: integer|ArrayLikeObject (optional) Pseudorandom number generator seed. The seed may be either a positive unsigned 32-bit integer or, for arbitrary length seeds, an array-like object containing unsigned 32-bit integers. options.state: Uint32Array (optional) Pseudorandom number generator state. If provided, the `seed` option is ignored. options.copy: boolean (optional) Boolean indicating whether to copy a provided pseudorandom number generator state. Setting this option to `false` allows sharing state between two or more pseudorandom number generators. Setting this option to `true` ensures that a returned generator has exclusive control over its internal state. Default: true. options.dtype: string (optional) Default output array data type. Default: 'float64'. options.order: string (optional) Default memory layout. Specifies whether an array is row-major (C-style) or column-major (Fortran-style). Default: 'row-major'. options.mode: string (optional) Default specifying how to handle indices which exceed array dimensions. If equal to 'throw', an ndarray instance throws an error when an index exceeds array dimensions. If equal to 'wrap', an ndarray instance wraps around indices exceeding array dimensions using modulo arithmetic. If equal to 'clamp', an ndarray instance sets an index exceeding array dimensions to either `0` (minimum index) or the maximum index. Default: 'throw'. options.submode: Array (optional) Default specifying how to handle subscripts which exceed array dimensions. If a mode for a corresponding dimension is equal to 'throw', an ndarray instance throws an error when a subscript exceeds array dimensions. If equal to 'wrap', an ndarray instance wraps around subscripts exceeding array dimensions using modulo arithmetic. If equal to 'clamp', an ndarray instance sets a subscript exceeding array dimensions to either `0` (minimum index) or the maximum index. If the number of modes is less than the number of dimensions, an ndarray instance recycles modes using modulo arithmetic. Default: [options.mode]. options.readonly: boolean (optional) Default indicating indicating whether an array should be read-only. Default: false. Returns ------- fcn: Function Function for creating arrays. Examples -------- > var fcn = {{alias}}.factory(); > var out = fcn( [ 3, 3 ], 2.0 ) {{alias}}.PRNG Underlying pseudorandom number generator. Examples -------- > var prng = {{alias}}.PRNG; {{alias}}.seed Pseudorandom number generator seed. Examples -------- > var seed = {{alias}}.seed; {{alias}}.seedLength Length of generator seed. Examples -------- > var len = {{alias}}.seedLength; {{alias}}.state Generator state. Examples -------- > var out = {{alias}}( [ 3, 3 ], 2.0 ) // Get a copy of the current state: > var state = {{alias}}.state > out = {{alias}}( [ 3, 3 ], 2.0 ) > out = {{alias}}( [ 3, 3 ], 2.0 ) // Set the state: > {{alias}}.state = state; // Regenerate a previous array: > out = {{alias}}( [ 3, 3 ], 2.0 ) {{alias}}.stateLength Length of generator state. Examples -------- > var len = {{alias}}.stateLength; {{alias}}.byteLength Size (in bytes) of generator state. Examples -------- > var sz = {{alias}}.byteLength; See Also --------