R/utils.R

Defines functions move_xy

# this function moves the coordinates to the first two variables of the df:
move_xy <- function(df) {
  nc <- ncol(df)
  sel <- c(nc - 1, nc)
  cbind(df[, sel], df[, -sel])
}
epix-project/sptools documentation built on Nov. 4, 2019, 11:55 a.m.