Check if spec MS/MS data and spec_metadata is proper aligned
Source:R/table_checks.R
check_MS_data_order.Rd
Internal Function *
Arguments
- spec
a data frame containing the extracted MS/MS spectra, the following columns are required:
- mz_precursor
- rt
- mz
- intensity
- spec_metadata
a data frame containing the values to be including in the resulting
.msp
file. The following columns are required as vital information for the .msp output.- NAME
- PRECURSORTYPE
- FORMULA
- RETENTIONTIME
- IONMODE
- COLLISIONENERGY
Details
This function is intended to check the order of the key of the spec data and the spec metadata. If both keys are aligned, the code continues. If the keys are not aligned, it aborts. This function will not try to align the keys, as the the keys are ordered back-end and key alignment is expected.
Checks in this function include:
Check equal number of MS/MS data and number of observations in spec_metadata
All key names are aligned