gtools (version 3.5.0)

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
  x <- 1:10
  permute(x)

Run the code above in your browser using DataCamp Workspace