change_meta: Change meta data

View source: R/organize_libraries_EI_and_MS2.R

change_metaR Documentation

Change meta data

Description

change_meta offers a way to change meta data (mainly used for in-house library).

Usage

change_meta(lib, CE = NA, instrument = NA, comment = NA, add = FALSE)

Arguments

lib

The in-house library generated by read_lib.

CE

User defined collision energy. If no CE is supplied, the CollisionEnergy field will not be changed.

instrument

User define instrument type. If no instrument is supplied, the InstrumentType field will not be changed.

comment

User define comment, e.g., Principle investigator, data collector, laboratory, etc.If no comment is supplied, the Comment field will not be changed. If you want to add new comment, please set "add = TRUE", then old and new comment will be separated by ";". Otherwise, the old comment will be covered by the new one.

add

A logical scalar. Whether to keep the old comment and add new comment behind or just replace the old comment. TRUE or FALSE.

Details

When you build your own mass spectral library (either EI or MS2 library), you might want to add or change some meta data, such as collision energy, instrument,and comment. This function provides an easy way to achieve this.

Value

A list with meta data assigned.


QizhiSu/mspcompiler documentation built on May 7, 2024, 4:25 a.m.