Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

removal of cs_smiles_inchi and cs_inchikey_inchi #275

Closed
korseby opened this issue Aug 3, 2020 · 2 comments
Closed

removal of cs_smiles_inchi and cs_inchikey_inchi #275

korseby opened this issue Aug 3, 2020 · 2 comments

Comments

@korseby
Copy link

korseby commented Aug 3, 2020

Hi,

it seems that the function cs_smiles_inchi has been removed in favour of cs_smiles_csid...

A similar thing occured with cs_inchikey_inchi...

I could not find any documentation of that. How can I get the same results as with cs_smiles_inchi / cs_inchikey_inchi with the latest version of webchem?

# Minimal example:
smile <- 'CC(C(O[C@H]([C@@H](OC(C(C)C)=O)[C@@H](OC(C(C)C)=O)O[C@@H]1CO)[C@@H]1O)=O)C'
webchem::cs_smiles_inchi(  smiles = smile,      verbose = FALSE)
@stitam
Copy link
Contributor

stitam commented Aug 4, 2020

Thank you @korseby for raising this issue and sorry for removing these functions without deprecating them first.

The alternative is now the cs_convert() function:

cs_convert("CC(C(O[C@H]([C@@H](OC(C(C)C)=O)[C@@H](OC(C(C)C)=O)O[C@@H]1CO)[C@@H]1O)=O)C", from = "smiles", to = "inchi", apikey = apikey)
[1] "InChI=1/C18H30O9/c1-8(2)15(21)25-13-12(20)11(7-19)24-18(27-17(23)10(5)6)14(13)26-16(22)9(3)4/h8-14,18-20H,7H2,1-6H3/t11-,12-,13+,14-,18-/m1/s1"

The function can convert between multiple identifiers, but not all conversions are supported through the new APIs. The list of supported conversions can be found in the function documentation. Does this answer your question?

@korseby
Copy link
Author

korseby commented Aug 6, 2020

Thanks. It just would have been great to find some documentation on this. Anyway. This fixes the issue. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants