![]() |
OpenMS
|
Writer for the feature-quantification (.TXT) table required by GNPS Feature-Based Molecular Networking. More...
#include <OpenMS/FORMAT/GNPSQuantificationFile.h>
Static Public Member Functions | |
| static void | store (const ConsensusMap &consensus_map, const std::string &output_file) |
| Write the FBMN feature-quantification table. | |
Writer for the feature-quantification (.TXT) table required by GNPS Feature-Based Molecular Networking.
For each consensus feature in a ConsensusMap, this writer emits one row giving the consensus-level rt_cf, mz_cf, intensity_cf, charge_cf, width_cf, quality_cf (in that order), optionally followed by IIMN columns if Constants::UserParam::IIMN_ROW_ID is set on the first feature, followed by per-map sub-feature columns. The file starts with #MAP and #CONSENSUS header lines and one MAP row per ConsensusMap::getColumnHeaders entry (id, filename, label, size). The format matches the schema at https://ccms-ucsd.github.io/GNPSDocumentation/featurebasedmolecularnetworking/#feature-quantification-table.
The file is required for FBMN (in contrast to the optional meta-value table). Produced by the GNPSExport tool.
|
static |
Write the FBMN feature-quantification table.
Output structure (tab-separated, written via SVOutStream):
"#MAP\\tid\\tfilename\\tlabel\\tsize" header."#CONSENSUS\\trt_cf\\tmz_cf\\tintensity_cf\\tcharge_cf\\twidth_cf\\tquality_cf" header, followed by IIMN columns (IIMN_ROW_ID, IIMN_BEST_ION, IIMN_ADDUCT_PARTNERS, IIMN_ANNOTATION_NETWORK_NUMBER) iff the first consensus feature carries IIMN_ROW_ID, then per-map sub-feature columns "rt_<i>\\tmz_<i>\\tintensity_<i>\\tcharge_<i>\\twidth_<i>".MAP row per consensus_map.getColumnHeaders entry.CONSENSUS row per consensus feature; missing per-map sub-features are filled with empty strings.| [in] | consensus_map | Consensus map whose column headers and features drive the rows. |
| [in] | output_file | Destination path for the TXT file (overwritten if it exists). |
Referenced by TOPPGNPSExport::main_().