changeset 4:1b8c54b9de55 draft

Uploaded
author deepakjadmin
date Wed, 06 Jan 2016 09:14:21 -0500
parents 64c804de0681
children 8dd76b4e7470
files addact.xml padelnew.xml removeduplecate.xml tool2/addact.pl tool2/addact.pl.copy tool3/removeduplecate.R tool_dependencies.xml
diffstat 7 files changed, 200 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/addact.xml	Wed Jan 06 09:14:21 2016 -0500
@@ -0,0 +1,29 @@
+<tool id="aaapadel002" name="Merge files">
+<description>"Merge data files of Active and Inactive compounds "</description>
+<command interpreter="perl">tool2/addact.pl $Input1 $Activity1 $Input2 $Activity2 $Merged_file</command>
+<inputs>
+<param format="csv" name="Input1" type="data" label="Descriptor File 1" help="Upload Active/Inactive descriptor file in csv format"/>
+  <!--param name="Activity1" type="select"  label="Choose Appropriate Lable">
+	<option value = "Active" selected="TRUE">Active</option>
+	<option value = "Inactive" >Inactive</option>
+  </param-->
+ <param name="Activity1" type="text" value="Active" label="Select type of molecules" help="write something which defines data eg active,positive,inactive,negative,etc." >
+   <validator type="empty_field" message="This field can't be left blank"/>
+        </param>
+
+ <param format="txt" name="Input2" type="data" label="Descriptor File 2" help="Upload Active/Inactive descriptor file in csv format"/>
+ <param name="Activity2" type="text" value="Inactive" label="Select type of molecules" help="write something which defines data eg active,positive,inactive,negative,etc.">
+   <validator type="empty_field" message="This field can't be left blank"/>
+        </param>
+ <!--param name="Activity2" type="select"  label="Choose appropriate Label">
+        <option value = "Inactive" selected= "TRUE">Inactive</option>
+        <option value = "Active" >Active</option>
+ </param-->
+</inputs>
+<outputs>
+<data format="csv" name="Merged_file" label="Merged Mega Descriptor File "/> 
+</outputs>
+<help>
+Provide descriptor files of active/positive and inactive/negative molecules and assign them properly. 
+</help>
+</tool>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/padelnew.xml	Wed Jan 06 09:14:21 2016 -0500
@@ -0,0 +1,76 @@
+<tool id="PaDEL789xsf1" name="PaDEL">
+<description>"PaDEL Descriptor Calculation Tool"</description>
+<command interpreter="">
+#if '.smi' in $input.name
+/bin/mkdir $input.extra_files_path;
+ln -s $input $input.extra_files_path/molecule.smi;
+/usr/bin/java -jar PaDEL-Descriptor.jar -dir $input.extra_files_path/molecule.smi -2d $detectaromaticity $removesalt $standardizenitro $convert3d $retain3d $coordinate  $fingerprint $retainorder -file $descriptor -log > $log ;
+/bin/rm -rf $input.extra_files_path;
+#else
+/usr/bin/java -jar PaDEL-Descriptor.jar -dir $input -2d $detectaromaticity $removesalt $standardizenitro $convert3d $retain3d $coordinate  $fingerprint $retainorder -file $descriptor -log >$log
+#end if
+</command>
+
+<inputs>
+	<param format="sdf" name="input" type="data" label="sdf/smile/mol2 file" optional= "false"/>
+  		
+	<param name="detectaromaticity" type="select" label="Detect the aroamaticity">
+        	<option value = "-detectaromaticity" selected="TRUE" >YES</option>
+		<option value = "" >NO</option>
+	</param>
+
+	<param name="removesalt" type="select" label="Remove salt">
+        	<option value = "-removesalt" selected="TRUE" >YES</option>
+		<option value = "" >NO</option>
+	</param>
+       
+        <param name="standardizenitro" type="select" label="Standardize nitro groups">
+        	<option value = "-standardizenitro" selected="TRUE" >YES</option>
+          	<option value = "" >NO</option>
+	</param>
+       
+        <param name="convert3d" type="select" label="convert in 3D">
+        	<option value = "" selected="TRUE" >NO</option>
+        	<option value = "-convert3d" >YES</option>
+  	</param>
+
+        <param name="retain3d" type="select" label="Retain 3D coordinates">
+        	<option value = "" selected="TRUE" >NO</option>
+        	<option value = "-retain3d" >YES</option>
+         	
+	</param>
+	
+	<param name="coordinate" type="select" label="calculate 3d descriptors">
+		<option value = "" selected="TRUE" >NO</option>
+		<option value = "-3d" >YES</option>
+	</param>
+
+	<param name="fingerprint" type="select"  label="calculate fingerprints">
+        	<option value = "" selected="TRUE" >NO</option>
+        	<option value = "-fingerprints">YES</option>
+	</param>
+
+	
+	<param name="retainorder" type="select" label="Retain molecules order">
+        	<option value = "-retainorder" selected="TRUE">YES</option>
+         	<option value = "" >NO</option>
+	</param>
+
+	
+	
+                  <!--
+<param name="3d" type="checkbox" label="Include 3D descriptors" description="add 3D descriptor" value="1" default="0" />
+<param name="fingerprint" type="checkbox" label="Include PubChem fingerprints" description="calculate 881 fingerprints" value="1" default="0" />
+-->
+	</inputs>
+
+<outputs>
+	<data format="csv" name="descriptor" label="Descriptors File of $input.name "/>
+	<data format="txt" name="log" label="Log File of $input.name"/>
+</outputs>
+
+<help>
+Input may be any sdf,smile or mol2 file  and output file will be in CSV format.
+</help>
+
+</tool>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/removeduplecate.xml	Wed Jan 06 09:14:21 2016 -0500
@@ -0,0 +1,13 @@
+<tool id="aaapadel003" name="Remove redundancy">
+<description>"Removes Repeated Entry From File"</description>
+<command interpreter="Rscript">tool3/removeduplecate.R $Input1 $Non_redudant_mega_file</command>
+<inputs>
+<param format="txt" name="Input1" type="data" label="Merged Descriptor File" help="csv format"/>
+</inputs>
+<outputs>
+<data format="csv" name="Non_redudant_mega_file" label="Non-redundant Mega Descriptor File"/> 
+</outputs>
+<help>
+run command with Descriptor file and in csv format only .output file will be in CSV format.
+</help>
+</tool>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tool2/addact.pl	Wed Jan 06 09:14:21 2016 -0500
@@ -0,0 +1,25 @@
+#!/usr/bin/perl 
+use warnings;
+use strict;
+open(FH,$ARGV[0])  or die "Couldn't open file, $!";
+open(DH,">$ARGV[4]") or die "Couldn't open file, $!";
+my $first_line = scalar <FH>;
+chomp($first_line);
+$first_line = join(",",$first_line,"outcome\n");
+print DH $first_line;
+while(<FH>){chomp($_);
+my $line= join(",",$_,"$ARGV[1]\n");
+print DH $line;
+}
+close FH;
+open(SH,$ARGV[2]) or die "Coudn't open file,$!";
+scalar <SH>;
+while(<SH>){ 
+if($ARGV[1] ne $ARGV[3]){chomp($_);
+my $line1= join(",",$_,"$ARGV[3]\n");
+print DH $line1;
+}
+else{ print ("There is error to assign activity\n");exit;}
+}
+close SH;
+close DH;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tool2/addact.pl.copy	Wed Jan 06 09:14:21 2016 -0500
@@ -0,0 +1,25 @@
+#!/usr/bin/perl 
+use warnings;
+use strict;
+open(FH,$ARGV[0])  or die "Couldn't open file, $!";
+open(DH,">tmp.txt") or die "Couldn't open file, $!";
+my $first_line = scalar <FH>;
+chomp($first_line);
+$first_line = join(",",$first_line,"outcome\n");
+print DH $first_line;
+while(<FH>){chomp($_);
+my $line= join(",",$_,"$ARGV[1]\n");
+print DH $line;
+}
+close FH;
+open(SH,$ARGV[2]) or die "Coudn't open file,$!";
+scalar <SH>;
+while(<SH>){ 
+if($ARGV[1] ne $ARGV[3]){chomp($_);
+my $line1= join(",",$_,"$ARGV[3]\n");
+print DH $line1;
+}
+else{ print ("There is error to assign activity\n");exit;}
+}
+close SH;
+close DH;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tool3/removeduplecate.R	Wed Jan 06 09:14:21 2016 -0500
@@ -0,0 +1,11 @@
+args <- commandArgs(TRUE)
+
+
+res1 <- read.csv(args[1])
+#res11 <- duplicated(res1[,1:length(res1) - 1])
+res11 <- duplicated(res1[,1])
+result <- res1[!res11,]
+names1 <- result[,1]
+rownames(result) <- names1
+result$Name <- NULL
+write.csv(result,file=args[2])
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tool_dependencies.xml	Wed Jan 06 09:14:21 2016 -0500
@@ -0,0 +1,21 @@
+<?xml version="1.0"?>
+<tool_dependency>
+    <package name="padel" version="2.21">
+        <install version="1.0">
+            <actions_group>
+                <actions os="linux" architecture="x86_64">
+                    <action type="download_by_url">http://www.yapcwsoft.com/dd/padeldescriptor/PaDEL-Descriptor.zip</action>
+                    <action type="move_directory_files">
+                        <source_directory>.</source_directory>
+                        <destination_directory>$INSTALL_DIR/bin/</destination_directory>
+                    </action>
+                </actions>
+                
+               <action type="set_environment">
+                    <environment_variable name="PATH" action="prepend_to">$INSTALL_DIR/bin</environment_variable>
+                </action>
+            </actions_group>
+        </install>
+        <readme></readme>
+    </package>
+</tool_dependency>