File tree Expand file tree Collapse file tree 2 files changed +16
-4
lines changed Expand file tree Collapse file tree 2 files changed +16
-4
lines changed Original file line number Diff line number Diff line change @@ -70,6 +70,14 @@ Class Strain
7070From 1
7171Tag Strain
7272
73-
73+ Colonne 8
74+ Width 40
75+ Optional
76+ Visible
77+ Class
78+ Class Text
79+ From 2
80+ Tag Name
81+
7482
7583// End of these definitions
Original file line number Diff line number Diff line change @@ -99,17 +99,21 @@ def parse_output(outfile)
9999 File . open ( outfile ) . each { |line |
100100 line . chomp!
101101 line . gsub! ( '"' , '' )
102+ isInAgr = false
103+ if line [ "AGRKB" ]
104+ isInAgr = true
105+ end
102106 if !line [ "Europe_PMC" ]
103107 c = line . split ( "\t " )
104108 if !results [ c [ 0 ] ]
105109 results [ c [ 0 ] ] = Hash . new # WBVarXXX
106110 results [ c [ 0 ] ] [ "name" ] = c [ 0 ] # WBVarXXX
107111 end
108- if !c [ 1 ] . empty?
112+ if !c [ 1 ] . empty? && isInAgr
109113 results [ c [ 0 ] ] [ "paper" ] ||=Hash . new # WBPaperXXX
110- results [ c [ 0 ] ] [ "paper" ] [ c [ 1 ] ] = ( c [ 4 ] . nil? or c [ 4 ] . empty? ) ? 'n/a' : c [ 4 ] # PubmedID
114+ results [ c [ 0 ] ] [ "paper" ] [ c [ 1 ] ] = ( ! c [ 4 ] . nil? && ! c [ 4 ] . empty? ) ? c [ 4 ] : 'n/a' # PubmedID
111115 end
112- if c [ 5 ]
116+ if c [ 5 ]
113117 results [ c [ 0 ] ] [ :strains ] ||=[ ] # WBStrains
114118 results [ c [ 0 ] ] [ :strains ] . push ( c [ 5 ] ) # adds WBStrainId
115119 end
You can’t perform that action at this time.
0 commit comments