index2xy {screenshot} | R Documentation |
Convert array index into xy location in matrix.
Helper function for locate_ndl_in_hay()
.
Description
Convert array index into xy location in matrix.
Helper function for locate_ndl_in_hay()
.
Usage
index2xy(index, nrow)
Arguments
index , nrow |
A numeric. |
Value
A numeric pair of xy location.
Examples
nrow <- 4
matrix(1:12, nrow = nrow)
purrr::map(1:12, index2xy, nrow = nrow)
[Package screenshot version 0.9.1 Index]