w********m 发帖数: 1137 | 1 readMERLIN <- function(infile) {
x <- file(infile, "r")
repeat {
rl <- readLines(x, n=1)
if (length(rl) == 0) break
if (length(grep("lnLikelihood", rl)) > 0) {
return( as.double(strsplit(rl, split= "=")[[1]][2]) )
}
}
}
y <- readMERLIN("test.txt")
analysis, |
|