[Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Zhengyh
Hello,

Thank you all who are helping me with this openbabel.
We use --join to join all input molecules into a single output
moleculeentry.
But which is the right function to do this in the pybel or openbable API?
I just can't find it...

Regards!


--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


Re: [Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Maciek Wójcikowski
Hi,

Have you tried mol1 += mol2? I use it for joining proteins with ligands,
but should work in any case.


Pozdrawiam,  |  Best regards,
Maciek Wójcikowski
mac...@wojcikowski.pl


2013/10/25 Zhengyh swanboi...@gmail.com

 Hello,

 Thank you all who are helping me with this openbabel.
 We use --join to join all input molecules into a single output
 moleculeentry.
 But which is the right function to do this in the pybel or openbable API?
 I just can't find it...

 Regards!



 --
 October Webinars: Code for Performance
 Free Intel webinars can help you accelerate application performance.
 Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most
 from
 the latest Intel processors and coprocessors. See abstracts and register 
 http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
 ___
 OpenBabel-discuss mailing list
 OpenBabel-discuss@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/openbabel-discuss

--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


Re: [Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Noel O'Boyle
Maciek hit send before I did :-)

a = pybel.readstring(smi, CC)
b = pybel.readstring(smi, CCO)
a.OBMol += b.OBMol
print a.write(smi)
...gives...
CC.CCO

On 25 October 2013 10:11, Zhengyh swanboi...@gmail.com wrote:
 Hello,

 Thank you all who are helping me with this openbabel.
 We use --join to join all input molecules into a single output
 moleculeentry.
 But which is the right function to do this in the pybel or openbable API?
 I just can't find it...

 Regards!


 --
 October Webinars: Code for Performance
 Free Intel webinars can help you accelerate application performance.
 Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
 the latest Intel processors and coprocessors. See abstracts and register 
 http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
 ___
 OpenBabel-discuss mailing list
 OpenBabel-discuss@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/openbabel-discuss

--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


Re: [Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Fredrik Wallner
Hi,

Wouldn't this be good to have exposed directly in pybel? Seems a bit 
non-intuitive to have to add the OBMols…

Kind regards,
Fredrik

25 okt 2013 kl. 11:28 skrev Noel O'Boyle baoille...@gmail.com:

 Maciek hit send before I did :-)
 
 a = pybel.readstring(smi, CC)
 b = pybel.readstring(smi, CCO)
 a.OBMol += b.OBMol
 print a.write(smi)
 ...gives...
 CC.CCO
 
 On 25 October 2013 10:11, Zhengyh swanboi...@gmail.com wrote:
 Hello,
 
 Thank you all who are helping me with this openbabel.
 We use --join to join all input molecules into a single output
 moleculeentry.
 But which is the right function to do this in the pybel or openbable API?
 I just can't find it...
 
 Regards!
 
 
 --
 October Webinars: Code for Performance
 Free Intel webinars can help you accelerate application performance.
 Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
 the latest Intel processors and coprocessors. See abstracts and register 
 http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
 ___
 OpenBabel-discuss mailing list
 OpenBabel-discuss@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/openbabel-discuss
 
 --
 October Webinars: Code for Performance
 Free Intel webinars can help you accelerate application performance.
 Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
 the latest Intel processors and coprocessors. See abstracts and register 
 http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
 ___
 OpenBabel-discuss mailing list
 OpenBabel-discuss@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/openbabel-discuss



signature.asc
Description: Message signed with OpenPGP using GPGMail
--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


Re: [Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Dimitri Maziuk
On 2013-10-25 04:33, Fredrik Wallner wrote:
 Hi,

 Wouldn't this be good to have exposed directly in pybel? Seems a bit 
 non-intuitive to have to add the OBMols…

To a programmer it's plenty intuitive. What's not intuitive to this 
programmer is if a and b have more than one possible binding site, how 
does it pick one.

Dima


--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


Re: [Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Geoffrey Hutchison
 (I would naively expect CC + CCO to produce  and H2O, but

There are obviously multiple possible *chemical* things one could imagine. But 
there’s no way code can or should make assumptions about chemical 
transformations.

We do have a chemical transformation class for handling reactions/modifications.

-Geoff


--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


Re: [Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Dimitri Maziuk
On 10/25/2013 01:48 PM, Geoffrey Hutchison wrote:
 (I would naively expect CC + CCO to produce  and H2O, but
 
 There are obviously multiple possible *chemical* things one could
imagine. But there’s no way code can or should make assumptions about
chemical transformations.

It's because my naive idea of a molecule is a thing with atoms and
bonds. So if I define
 molecule + molecule = molecule
I expect the result to be a single molecule with a bond where the '+' was.

I.e. I'd expect
OBMol + OBMol = OBMol to be something that creates a bond whereas
OBMol + OBMol = (OBMol, OBMol) is a set of disjoint molecules, no
strings attached.

-- 
Dimitri Maziuk
Programmer/sysadmin
BioMagResBank, UW-Madison -- http://www.bmrb.wisc.edu



signature.asc
Description: OpenPGP digital signature
--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


Re: [Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Igor Filippov
 a molecule is a thing with atoms and bonds.

Hmmm, no salts? No organometalics?


On Fri, Oct 25, 2013 at 3:08 PM, Dimitri Maziuk dmaz...@bmrb.wisc.eduwrote:

 On 10/25/2013 01:48 PM, Geoffrey Hutchison wrote:
  (I would naively expect CC + CCO to produce  and H2O, but
 
  There are obviously multiple possible *chemical* things one could
 imagine. But there’s no way code can or should make assumptions about
 chemical transformations.

 It's because my naive idea of a molecule is a thing with atoms and
 bonds. So if I define
  molecule + molecule = molecule
 I expect the result to be a single molecule with a bond where the '+' was.

 I.e. I'd expect
 OBMol + OBMol = OBMol to be something that creates a bond whereas
 OBMol + OBMol = (OBMol, OBMol) is a set of disjoint molecules, no
 strings attached.

 --
 Dimitri Maziuk
 Programmer/sysadmin
 BioMagResBank, UW-Madison -- http://www.bmrb.wisc.edu



 --
 October Webinars: Code for Performance
 Free Intel webinars can help you accelerate application performance.
 Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most
 from
 the latest Intel processors and coprocessors. See abstracts and register 
 http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk
 ___
 OpenBabel-discuss mailing list
 OpenBabel-discuss@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


Re: [Open Babel] Which is the function in API doing the same thing as --join

2013-10-25 Thread Dimitri Maziuk
On 10/25/2013 02:11 PM, Igor Filippov wrote:
 a molecule is a thing with atoms and bonds.
 
 Hmmm, no salts? No organometalics?

I didn't say you have to define bond as (e.g.) peptide-only. As long
as you know something's holding this carbon and this metal more or less
together...

-- 
Dimitri Maziuk
Programmer/sysadmin
BioMagResBank, UW-Madison -- http://www.bmrb.wisc.edu



signature.asc
Description: OpenPGP digital signature
--
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register 
http://pubads.g.doubleclick.net/gampad/clk?id=60135991iu=/4140/ostg.clktrk___
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss