Creat macro file and run, but cant open the created dwar file [message #630] |
Wed, 18 September 2019 11:16 |
dongkeke
Messages: 7 Registered: June 2019 Location: 中国
|
Junior Member |
|
|
Dear Thomas,
I create a macro file that import txt-file with chmical smiles to datawarrior, and creates the imageand then closes the datawarrior application. Then I open the macro file in windows, and I get a dwar file. But when I open the created dwar file, it occured a message like the attached picture.
I checked the dwar file, and found there are some settings. When I modify the three number as 0.5, the dwar file could be opened normally. But the seeting would not be recorded in the macro file. How can I open the dwar file in a correct way.
"<mainViewCount="5">
<mainViewDockInfo0="root">
<mainViewDockInfo1="Table bottom -0.006">
<mainViewDockInfo2="2D View center">
<mainViewDockInfo3="Table right -0.005">
<mainViewDockInfo4="3D View_raw right -0.005">"
Another question is that I can not import the file with chemical smiles in Linux. It is stucked in the process of converting smiles.
Thanks,
kelly
-
Attachment: message.PNG
(Size: 12.85KB, Downloaded 830 times)
Dong_Keke
|
|
|
Re: Creat macro file and run, but cant open the created dwar file [message #631 is a reply to message #630] |
Wed, 18 September 2019 23:26 |
nbehrnd
Messages: 224 Registered: June 2019
|
Senior Member |
|
|
Dear Kelly,
in my experience, there is more than one form of «SMILES». Just today I faced this
again with SMILES exported from the CCDC database' Python API where a few of them
were not compatible with DW. Most of them were curated successfully with openbabel,
translating these into its default SMILES format accessible for DW. This may be done
in babel's GUI, but if you have many SMILES codes to convert and already in a file, it
is often more convenient to perform this on the terminal. If this does not help, it
still is possible to try openbabel's translation into «canonical SMILES». While the
two SMILES differ, depending on using either default or canonical SMILES, DW typically
understands at least one of them smoothly. So I would suggest to check if the import
of your structures into DW with «reformatted SMILES» still stalls.
As example I attach the list of SMILES originally generated from the CCDC API and its
subsequent import in DW, which did not work completely. But both openbabel's SMILES
worked fine (two SMILES lists and one almost complete DW import.) The machine where
the CCDC database was installed was running Windows, the one eventually passing the data
to DW was Linux. While this was a smooth transition, maybe yours got malformatted for
the different line endings in the operational systems. In many Linuxes, there is the
dos2unix utility allowing to curate this while passing from Windows to Linux / Mac to
Linux and back.
Norwid
http://openbabel.org/wiki/Main_Page
http://dos2unix.sourceforge.net/
|
|
|
|
|
|
Re: Creat macro file and run, but cant open the created dwar file [message #658 is a reply to message #635] |
Wed, 09 October 2019 23:42 |
thomas
Messages: 715 Registered: June 2014
|
Senior Member |
|
|
Dear Kelly,
sorry for the late reply. Would it be possible to send me a small example macro, such that I can reproduce the issue. And also may an example of the SMILES file that is causing the trouble? DataWarrior should never crash, when reading SMILES, even if the SMILES are invalid. Invalid SMILES should simply be ignored.
Thanks in advance, Thomas
|
|
|