if (FALSE) {
# To run this example, ensure that MS Search (NIST) software is installed.
# Reading the 'alkanes.msp' file
msp_file <- system.file("extdata", "alkanes.msp", package = "mssearchr")
msp_objs <- ReadMsp(msp_file)
# Searching using the MS Search (NIST) API
hitlists <- LibrarySearchUsingNistApi(msp_objs)
print(hitlists[[1]][1:5, ])
#> name mf rmf prob lib cas formula mw id ri
#> 1 UNDECANE 951 960 55.70 massbank_alkanes 0 C11H24 156 11 0
#> 2 UNDECANE 928 928 20.34 massbank_alkanes 0 C11H24 156 72 0
#> 3 DODECANE 906 929 8.04 massbank_alkanes 0 C12H26 170 74 0
#> 4 TRIDECANE 892 907 5.03 massbank_alkanes 0 C13H28 184 41 0
#> 5 DODECANE 886 900 3.95 massbank_alkanes 0 C12H26 170 42 0
}
Run the code above in your browser using DataLab