Collections:
"babel ... -o svg -xC" - Hide Terminal C in SVG
How to hide those C symbols for terminal carbon atoms in SVG with the "babel" command?
✍: FYIcenter.com
If you want to hide those C symbols for terminal carbon atoms in SVG format,
you can use the "-o svg -xC" option with the "babel" command.
Here is how the "-xC" option is described in Open Babel help document: "C - do not draw terminal C (and attached H) explicitly The default is to draw all hetero atoms and terminal C explicitly, together with their attached hydrogens."
For example, the following command generate a SVG picture without C symbols for terminal carbon atoms for the aspirin molecule:
fyicenter$ obabel "-:O=C(Oc1ccccc1C(=O)O)C" -O aspirin-no-carbon.svg --gen2D -xC 1 molecule converted
As a comparison, running the following command generates a SVG picture with C symbols for terminal carbon atoms for the same molecule:
fyicenter$ obabel "-:O=C(Oc1ccccc1C(=O)O)C" -O aspirin.svg --gen2D 1 molecule converted
Open both output files, aspirin.svg and aspirin-no-carbon.svg, in a Web browser, you see the differences:
⇒ "babel -i sdf -o svg" - Custom Atom Positions
⇐ "babel ... -o svg -xX" - Hide Implicit H in SVG
2020-07-22, 1508🔥, 0💬
Popular Posts:
Molecule Summary: ID: FYI-1005071 Names: InChIKey: OUSFTKFNBAZUKL-UHFFFAOYS A-NSMILES: CC(C)(C)c3cnc...
Molecule Summary: ID: FYI-1001516 SMILES: C#CC1=CC=CC2=C1C=C(NC(NC CCN)=O)N=C2NReceived at FYIcenter...
Molecule Summary: ID: FYI-1001251 SMILES: O=C(/C=C\\c1cccc(O)c1)N1 N=C(c2ccncc2)OC1c1c[nH]c 2ccccc12R...
Molecule Summary: ID: FYI-1006095 Names: InChIKey: MOYZEMOPQDTDHA-YQYZCKNZS A-NSMILES: C1C(CC2C3C(C1...
Molecule Summary: ID: FYI-1006519 Names: InChIKey: ZQPJZDYDQDYJRX-UHFFFAOYS A-NSMILES: CCCCCCCCCCCCC...