Learn R Programming

gtools (version 3.9.5)

permute: Randomly Permute the Elements of a Vector

Description

Randomly Permute the elements of a vector

Usage

permute(x)

Value

Vector with the original items reordered.

Arguments

x

Vector of items to be permuted

Author

Gregory R. Warnes greg@warnes.net

Details

This is simply a wrapper function for sample.

See Also

Examples

Run this code

x <- 1:10
permute(x)

Run the code above in your browser using DataLab