girke-lab / ChemmineR-git-svn-bridge

This is defunct, now replaced with https://github.com/girke-lab/ChemmineR
2 stars 6 forks source link

truncated atomblock representation of single hydrogen #41

Closed anastasiiaNG closed 4 years ago

anastasiiaNG commented 4 years ago

Hi, when using ChemmineR to automatically process .rxn files by the following pipeline, I noticed that single hydrogens have truncated atomblok representation (see below). Because of that I lose some information from the omitted columns and moreover it makes it hard to automatically process such output as there are different numbers of columns in the atomblocks.

ttt <- ChemmineR::read.SDFindex("ECBLAST_R05314_AAM.rxn", 
                                index = data.frame(
                                  "A" = which(stringr::str_detect(rdt_lines, "C[:digit:]{5}")), 
                                  "B" = which(stringr::str_detect(rdt_lines, "END"))
                                ))
ChemmineR::atomblock(ttt)

... $CMP5 C1 C2 C3 C5 C6 C7 C8 C9 C10 C11 C12 C13 C14 C15 C16 O_1 -0.201 -0.75 0 0 0 0 0 0 0 0 0 0 45 0 0 C_2 1.299 -0.75 0 0 0 0 0 0 0 0 0 0 46 0 0 O_3 2.799 -0.75 0 0 0 0 0 0 0 0 0 0 47 0 0

$CMP6 C1 C2 0 0 0

ECBLAST_R05314_AAM.txt has the following text inside:

... $MOL C00011 EC-BLAST 1216190603

3 2 0 0 0 0 0 0 0 0999 V2000 -0.2010 -0.7500 0.0000 O 0 0 0 0 0 0 0 0 0 45 0 0 1.2990 -0.7500 0.0000 C 0 0 0 0 0 0 0 0 0 46 0 0 2.7990 -0.7500 0.0000 O 0 0 0 0 0 0 0 0 0 47 0 0 2 1 2 0 0 0 0 2 3 2 0 0 0 0 M END $MOL C00080 EC-BLAST 1216190603

1 0 0 0 0 0 0 0 0 0999 V2000 0.0000 0.0000 0.0000 H 0 0 0 0 0 0 0 0 0 57 0 0 M CHG 1 1 1 M END

tgirke commented 4 years ago

Thanks for bringing this up. - Currently, rxn is not one of the molecule file formats supported in ChemmineR. If it is important and likely to be used by a larger number of users, then please make a feature request, so that we can add it to the to-do list. For this please provide a reproducible example, name and formal description of the format so that we can follow those guidelines. Thanks. - Thomas