agentsclimarketplace

Mass spectrometry column polarity filtering

Skill HolobiomicsLab/asb-skill-collections/collections/metabolomics/v1/skills/mass-spectrometry-column-polarity-filtering

Use when you have a combined EI library (from multiple sources such as NIST, RIKEN, MoNA) and access to NIST RI database files (ri.dat and USER.From its SKILL.md

Install
npx -y skills add HolobiomicsLab/asb-skill-collections --skill mass-spectrometry-column-polarity-filtering

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 15 stars15 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its file declares

Copied from the file, not written here

The file declares its own license as CC-BY-4.0. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.

SKILL.md

5.5 KB, ~1.0k tokens by cl100k_base, as published. Nobody here has run it

mass-spectrometry-column-polarity-filtering

Summary

Filter and assign experimental Kovats retention index (RI) values to a compiled EI mass spectral library based on gas chromatography column polarity. This skill ensures that only RI measurements from appropriate capillary GC columns are retained and that RI records meeting quality thresholds are propagated into the final library.

When to use

Apply this skill when you have a combined EI library (from multiple sources such as NIST, RIKEN, MoNA) and access to NIST RI database files (ri.dat and USER.DBU), and you need to enrich the library with experimentally validated Kovats RI values while filtering by column type (semi-polar, non-polar, or polar capillary GC columns).

When NOT to use

  • Input library already contains validated RI values from capillary GC columns and does not require re-filtering or enrichment.
  • NIST RI database files (ri.dat, USER.DBU) are not available or accessible.
  • The analysis goal is to preserve all RI records regardless of column type or measurement variability rather than applying quality-based filtering.

Inputs

  • compiled EI library object (e.g., from read_lib or combined from multiple sources)
  • NIST ri.dat file (Kovats RI database)
  • NIST USER.DBU file (user-defined RI records)

Outputs

  • EI library object with populated RI fields
  • MSP format file with RI values assigned and polarity-filtered

How to apply

First, extract experimental Kovats RI data from NIST ri.dat and USER.DBU files using extract_ri(), which parses the NIST RI database. Then apply assign_ri() to the combined library object, specifying the column polarity (e.g., 'semi-polar') to filter and retain only RI records from capillary GC columns. During assignment, the function automatically discards RI values where the standard deviation exceeds 30; when multiple RI records exist for a single compound, the median RI is computed and used. Verify population of RI fields by inspecting the RI column in the output library object or writing the output to MSP format and confirming RI presence in the resulting file.

Related tools

Examples

nist_ri <- extract_ri("D:/MS_libraries/ri.dat", "D:/MS_libraries/USER.DBU"); combine_ei <- assign_ri(combine_ei, nist_ri, polarity = "semi-polar")

Evaluation signals

  • RI field is populated in output library object for compounds with valid records matching the specified polarity.
  • RI values show absence of records with standard deviation > 30; median RI is used when multiple records per compound exist.
  • Only RI records from capillary GC columns are retained; 'Lee RI' and non-capillary entries are removed.
  • Written MSP output file contains RI values in the RI field for enriched compounds.
  • Cross-check: inspect a sample of library entries before/after assign_ri to confirm RI population and absence of invalid outliers.

Limitations

  • assign_ri filtering only applies to capillary GC columns; RI records from packed or other column types are discarded regardless of quality.
  • RI values with standard deviation exceeding 30 are unconditionally removed, which may exclude valid measurements in systems with inherent variability.
  • If no NIST RI database is available or installed locally, extract_ri cannot retrieve experimental RI data.
  • Median RI calculation assumes that multiple records for the same compound represent equivalent or comparable measurements; this may not hold across different laboratories or instrument configurations.

Evidence

  • [methods] Extract experimental RI from NIST files: "Extract experimental Kovats RI data from NIST ri.dat and USER.DBU files using extract_ri"
  • [readme] Assign RI based on polarity and quality thresholds: "The polarity can be "semi-polar", "non-polar", or "polar". Providing that "capillary" GC columns are commonly used. This function will only keep RI records from "capillary" columns and "Lee RI" will"
  • [other] Verify RI population in output: "Verify that RI fields are populated in the resulting library object by inspecting the RI column in the output or writing the output to MSP format using write_EI_msp and confirming RI presence in the"
  • [readme] Sequential workflow with RI assignment: "After read in and organize all these libraries, we can now combine them into a single file, assign experimental RI retrieved from the "ri.dat" and "USER.DBU" files (if you have NIST library"

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.