R: Generate Halton Value (Randomly Initialized)

generate_halton_random_single {spacefillr} | R Documentation

## Generate Halton Value (Randomly Initialized)

### Description

Generate a single value from a seeded Halton set.

Note: This is much slower than generating the entire set ahead of time.

### Usage

    generate_halton_random_single(i, dim, seed = 0)

### Arguments

`i` | The element of the sequence to extract.
`dim` | The dimension of the sequence to extract.
`seed` | Default '0'. The random seed.

### Value

A single numeric value representing the 'i'th element in the 'dim' dimension.

### Examples

    #Generate a 3D sample:
    point3d = c(generate_halton_random_single(10, dim = 1),
               generate_halton_random_single(10, dim = 2),
               generate_halton_random_single(10, dim = 3))
    point3d

    #Change the random seed:
    #'#Generate a 3D sample
    point3d_2 = c(generate_halton_random_single(10, dim = 1, seed = 10),
                 generate_halton_random_single(10, dim = 2, seed = 10),
                 generate_halton_random_single(10, dim = 3, seed = 10))
    point3d_2

[Package spacefillr version 0.2.0 Index]