| 
		
			| ChemAxon calculated properties [message #4] | Fri, 25 July 2014 21:16  |  
			| 
				
				
					|  drc007 Messages: 2
 Registered: July 2014
 | Junior Member |  |  |  
	| I'm having a look at DataWarrior and I'd like to calculate most basic pKa using the ChemAxon tools which I have installed. When I open an sdf file with DataWarrior and select Add calculated properties I find the ChemAxon tools are greyed out. |  
	|  |  | 
	| 
		
			| Re: ChemAxon calculated properties [message #5 is a reply to message #4] | Sat, 02 August 2014 12:37   |  
			| 
				
				|  |  ffadmin Messages: 4
 Registered: June 2014
 | Junior MemberAdministrator
 |  |  |  
	| the pKa and logD calculation are not available in the free DataWarrior version, because they require commercial software from ChemAxon, the pKa plugin, which
 Actelion has licensed for internal usage, but cannot provide to the public.
 
 However, if you have a license to the necessary subset of the ChemAxon software,
 you may put all ChemAxon files needed for pKa calculation into a new .jar file
 (this is a zip file with extention 'jar' instead of 'zip') call it 'capka.jar'
 and copy it into the datawarrior installation directory that includes all
 other jar files. DataWarrior would recognize the file and would enable the options
 for pKa and logD. Since finding the needed files is a little tricky, you may
 unpack all ChemAxon jar-files into one directory, zip them again and rename
 to 'capka.jar'.
 
 I realize that this is a little cumbersome, but currently there is no other
 solution.
 
 Hope this helps,
 
 Thomas
 |  
	|  |  | 
	|  | 
	| 
		
			| Re: ChemAxon calculated properties [message #29 is a reply to message #28] | Thu, 04 December 2014 22:55   |  
			| 
				
				
					|  thomas Messages: 736
 Registered: June 2014
 | Senior Member |  |  |  
	| DataWarrior is looking for a file name 'capka.jar' in the same directory, where datawarrior.jar is located. If it finds this file and if it contains the needed Java classes, it will work.
 
 If you want to do that, there are two options:
 
 The easy one: Unpack all ChemAxon jar files into one directory and zip them again into one
 big jar that you rename to 'capka.jar'. This should work, but the disadvantage is that
 the file will be more than 100Mbyte in size.
 
 The difficult one: Unpack all ChemAxon jar files into one directory, remove the file that
 are not needed and zip the rest into one jar that you rename to 'capka.jar'. This works and
 results in a file that is less than 1Mbyte. The problem: Locating the unneeded files is
 rather cumbersome. I tried with two obfuscators to track dependencies and purge the rest.
 This didn't work for various reasons. The approach that worked, is the following:
 I wrote a java program that used the ChemAxon API to create a ChemAxon Molecule object
 from a molfile, to predict the pKa values, then checked the values and wrote an empty
 text file 'OK.txt' to indicate that the ChemAxon API worked correctly. Then, I set the
 Java classpath to access the ChemAxon API from the unpacked folder with all ChemAxon class
 and data files. Then I used a linux script to stepwise delete one file after another from
 the ChemAxon directory with checking whether OK.txt was written. If not I undeleted the
 evidently necessary file and went to the next. That gave me the core set of needed files.
 The I noticed that different molfile/molecule features required additional classes to work,
 which I added manually when the ClassNotFoundException was raised. Evidently, ChemAxon
 software uses heavily Class.forName() calls, whenever a molfile contains a specific feature.
 If you are brave enough to go through this, I can send you the Linux scripts I used to create
 the file.
 
 If you are running Linux or OSX, you have a third option. Put all the ChemAxon jar files in
 the directory that contains datawarrior.jar and add all ChemAxon jar file names to the class
 path. On linux this is in the file 'datawarrior'. On OSX it is in Info.plist. You can access
 that file if you click right mouse on the DataWarrior icon, select 'Show Package Content'
 and open the 'Contents' folder.
 
 I am sorry for the cumbersome stuff, but for obvious reasons I cannot send you a copy of the
 capka.jar file.
 
 Good luck,
 
 Thomas
 
 |  
	|  |  | 
	|  | 
	|  | 
	|  | 
	|  | 
	|  | 
	|  | 
	|  | 
	|  | 
	|  |