Columns from y that are not in x are merged into x. Columns in x and
y are considered equal if they have the same name, the same content, and
the same label.
merge_data(x, y)
| x | hyperSpec object into which extra data columns of y are to be merged |
|---|---|
| y | hyperSpec object with further extra data columns |
x amended with columns from y
Columns with different content than a column in x with the same name will
get ".y" appended to its name.
merge_data() relies on x and y having the same row order.
tmp <- flu[, FALSE, ] tmp$prediction <- 1:6 tmp#> hyperSpec object #> 6 spectra #> 2 data columns #> 0 data points / spectrummerge_data(flu, tmp)#> hyperSpec object #> 6 spectra #> 4 data columns #> 181 data points / spectrum