Learn R Programming

gtools (version 3.9.2)

permute: Randomly Permute the Elements of a Vector

Description

Randomly Permute the elements of a vector

Usage

permute(x)

Arguments

x

Vector of items to be permuted

Value

Vector with the original items reordered.

Details

This is simply a wrapper function for sample.

See Also

sample

Examples

Run this code
# NOT RUN {
x <- 1:10
permute(x)
# }

Run the code above in your browser using DataLab