Convert cell reference strings from A1 to R1C1 format
Convert cell reference strings from A1 to R1C1 format. Strictly speaking,
this only makes sense for absolute references, such as "$B$4"
. Why?
Because otherwise, we'd have to know the host cell of the reference. Set
strict = FALSE
to relax and treat pure relative references, like
("B4"
), as if they are absolute. Mixed references, like
("B$4"
), will always return NA
, no matter the value of
strict
.
A1_to_R1C1(x, strict = TRUE)
x |
character vector of cell references in A1 format |
strict |
logical, affects reading and writing of A1 formatted cell
references. When |
character vector of absolute cell references in R1C1 format
A1_to_R1C1("$A$1") A1_to_R1C1("A1") ## raises a warning, returns NA A1_to_R1C1("A1", strict = FALSE) ## unless strict = FALSE A1_to_R1C1(c("A1", "B$4")) ## raises a warning, includes an NA, because A1_to_R1C1(c("A1", "B$4"), strict = FALSE) ## mixed ref always returns NA
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.