Rename columns in a flowSet
Usage
# S3 method for flowSet
rename_with(.data, .fn, .cols = dplyr::everything(), ...)
Arguments
- .data
A
flowSet
- .fn
A function used to transform the selected .cols. Should return a character vector the same length as the input.
- .cols
Unquoted column names indicating which columns to rename (as specified by the
featureNames
of theflowFrame
s making up theflowSet
).- ...
Additional arguments passed onto .fn.
Value
An object of the same type as .data. The output has the following properties:
* Rows are not affected.
* Column names are changed; column order is preserved.
* The flowSet
's pData
will be preserved.
Examples
my_flowset <- simulate_cytometry_data()$flowset
my_flowset |>
dplyr::rename_with(.fn = toupper)
#> A flowSet with 5 experiments.
#>
#> column names(10): FEATURE_1 FEATURE_2 ... FEATURE_9 FEATURE_10
#>