compute_random_walk: compute_random_walk

View source: R/Simulate_Data.R

compute_random_walkR Documentation

compute_random_walk

Description

Compute a (Gaussian) random walk.

Usage

compute_random_walk(n, p, mu, sigma, start = rep(0, n))

Arguments

n

an integer, the number of random walks.

p

an integer, the length of the random walks.

mu

a numerical vector, the mean of the random walks.

sigma

a numerical value which is the standard deviation of the gaussian distribution used to compute the random walks.

start

a numerical vector (optional) which is the initial value of the random walks.

Details

See the sim_x function.

Value

a matrix where each row is a random walk.

Examples

# see the sim_x() function.

bliss documentation built on May 29, 2024, 8:35 a.m.