Learn R Programming

quincunx (version 0.1.9)

subset-sample_sets: Subset a sample_sets object

Description

You can subset sample_sets by identifier or by position using the `[` operator.

Usage

# S4 method for sample_sets,missing,missing,missing
[(x, i, j, ..., drop = FALSE)

# S4 method for sample_sets,numeric,missing,missing [(x, i, j, ..., drop = FALSE)

# S4 method for sample_sets,character,missing,missing [(x, i, j, ..., drop = FALSE)

Value

A sample_sets object.

Arguments

x

A sample_sets object.

i

Position of the identifier or the name of the identifier itself.

j

Not used.

...

Additional arguments not used here.

drop

Not used.

Examples

Run this code
if (FALSE) { # interactive()
# Get a few sample sets:
my_pss <- get_sample_sets(sprintf('PSS%06d', 42:48))

#
# Subsetting by position
#
my_pss[c(1, 3)]

#
# Subsetting by sample set identifier (character)
#
my_pss['PSS000042']
}

Run the code above in your browser using DataLab