Index: trunk/tools/wsor/message_templates/R/R_helper_functions.R |
— | — | @@ -205,19 +205,20 @@ |
206 | 206 | print(output) |
207 | 207 | |
208 | 208 | # Extend the data frames |
209 | | - |
210 | | - for (i in 2:length(template_indices_test)) |
211 | | - { |
| 209 | + |
| 210 | + if (length(template_indices) > 1) |
| 211 | + for (i in 2:length(template_indices)) |
| 212 | + { |
| 213 | + |
| 214 | + index <- template_indices[i] |
| 215 | + filename <- paste(fname_first_part, index, fname_last_part, sep="") |
| 216 | + |
| 217 | + output <- paste("Processing data from",filename,"....") |
| 218 | + print(output) |
| 219 | + |
| 220 | + temp_frame = read.table(filename, na.strings="\\N", sep="\t", comment.char="", quote="", header=T) |
| 221 | + metrics <- append.data.frames(metrics, temp_frame) |
| 222 | + } |
212 | 223 | |
213 | | - index <- template_indices[i] |
214 | | - filename <- paste(fname_first_part, index, fname_last_part, sep="") |
215 | | - |
216 | | - output <- paste("Processing data from",filename,"....") |
217 | | - print(output) |
218 | | - |
219 | | - temp_frame = read.table(filename, na.strings="\\N", sep="\t", comment.char="", quote="", header=T) |
220 | | - metrics <- append.data.frames(metrics, temp_frame) |
221 | | - } |
222 | | - |
223 | 224 | metrics |
224 | 225 | } |
\ No newline at end of file |