make_numeric_indices: Convert indices to numerical indices

View source: R/utils.R

make_numeric_indicesR Documentation

Convert indices to numerical indices

Description

Converts (possibly) logical indices to numerical ones. Also ensures unique indices and sorts them if specified.

Usage

make_numeric_indices(ind, n = NULL, unique = TRUE, sort = TRUE)

Arguments

ind

The numerical or logical index vector

n

Max numerical index (used if ind is logical and might be recycled)

unique

Whether to keep every (numerical) index at most once

sort

Whether to sort the numerical indices

Value

A numerical index vector


graphicalExtremes documentation built on Nov. 14, 2023, 1:07 a.m.