R.utils (version 1.0.1)

seqToHumanReadable: Gets a short human readable string representation of an vector of indices

Description

Gets a short human readable string representation of an vector of indices.

Usage

## S3 method for class 'default}(idx, delimiter="-", collapse=", ", ...)':
seqToHumanReadableundefined

idx{A vector of integer indices.}
  delimiter{A character string delimiter.}
  collapse{A character string used to collapse subsequences.}
  ...{Not used.}

[object Object]

print(seqToHumanReadable(1:10))  # "1-10"
  print(seqToHumanReadable(c(1:10, 15:18, 20)))  # "1-10, 15-18, 20"


attribute

Arguments