powered by
takes a string of the form "x(dx)", where dx are the error digits and returns a numeric vector c(x, y), where y is dx as a proper numeric value.
string2error(x)
Input character string.
a numeric vector with the first element the value and the second the error
can be used in combination with apply
# NOT RUN { string2error("0.35667(25)") s <- c("0.35667(25)", "0.667(50)") apply(array(s, dim=c(1, length(s))), 2, string2error) # }
Run the code above in your browser using DataLab