mirror of
https://github.com/msberends/AMR.git
synced 2025-07-08 22:41:52 +02:00
scientific notation for MICs
This commit is contained in:
2
R/mic.R
2
R/mic.R
@ -184,6 +184,8 @@ as.mic <- function(x, na.rm = FALSE) {
|
||||
|
||||
# comma to period
|
||||
x <- gsub(",", ".", x, fixed = TRUE)
|
||||
# transform scientific notation
|
||||
x[x %like% "[-]?[0-9]+([.][0-9]+)?e[-]?[0-9]+"] <- as.double(x[x %like% "[-]?[0-9]+([.][0-9]+)?e[-]?[0-9]+"])
|
||||
# transform Unicode for >= and <=
|
||||
x <- gsub("\u2264", "<=", x, fixed = TRUE)
|
||||
x <- gsub("\u2265", ">=", x, fixed = TRUE)
|
||||
|
Reference in New Issue
Block a user