next_permutation: Get the next permutation

View source: R/createGroups.r

next_permutationR Documentation

Get the next permutation

Description

Each permutation is computed on basis of a passed permutation where lexicographic ordering of the permutations is used to determine the next "higher" permutation. This is an adaption of the 'next_permutation' function in C++.

Usage

next_permutation(permutation)

Arguments

permutation

A vector of elements.

Value

The next higher permutation of the elements in vector 'permutation' with regard to its lexicographic ordering.

Author(s)

Martin Papenberg martin.papenberg@hhu.de


m-Py/minDiff documentation built on July 4, 2022, 3:58 p.m.