summaryrefslogtreecommitdiff
path: root/scripts/hansen2csv.rb
diff options
context:
space:
mode:
authorChristoph Helma <helma@in-silico.ch>2018-11-05 17:37:29 +0100
committerChristoph Helma <helma@in-silico.ch>2018-11-05 17:37:29 +0100
commit2361c6d9259e7ec8eea97f9bff3b24d105b3662a (patch)
treec8c6a869cf0af40b03ae4bd33ae48cbe4dfd5532 /scripts/hansen2csv.rb
parentba5372ce84bd89a937478d32eb067995214f1331 (diff)
adjustments for latest lazar version
Diffstat (limited to 'scripts/hansen2csv.rb')
-rwxr-xr-xscripts/hansen2csv.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/scripts/hansen2csv.rb b/scripts/hansen2csv.rb
new file mode 100755
index 0000000..3ae22ee
--- /dev/null
+++ b/scripts/hansen2csv.rb
@@ -0,0 +1,10 @@
+#!/usr/bin/env ruby
+require 'csv'
+require_relative '../../lazar/lib/lazar.rb'
+
+puts "ID,SMILES,Mutagenicity"
+i = 0
+CSV.foreach(ARGV[0]) do |row|
+ puts [row[0],row[5],row[2]].join "," if i > 0
+ i += 1
+end