nchoosek {vsn} | R Documentation

## List all subsets of size k from n objects

### Description

List all subsets of size k from n objects

### Usage

    nchoosek(n, k)

### Arguments

`n` | Integer
`k` | Integer

### Value

A matrix with k rows and as many columns as there are distinct subsets. Each column contains integers between 1 and n, and represents a subset.

### See Also

`choose`

### Examples

    nchoosek(5,3)

[Package vsn version 1.8.0 Index]