recode_subquad: Recode subquadrat.

View source: R/add_subquad.R

recode_subquadR Documentation

Recode subquadrat.

Description

Recode subquadrat.

Usage

recode_subquad(data, offset = -1)

Arguments

data

A dataframe with the variable subquadrat.

offset

A number; either -1 or 1, to rest or add one unit to the number of column of each subquadrat.

First column is 0    First column is 1
-----------------    -----------------
   04 14 24 34          14 24 34 44
   03 13 23 33          13 23 33 43
   02 12 22 32          12 22 32 42
   01 11 21 31          11 21 31 41

Value

A modified version of the input.

Examples

first_subquad_11 <- tibble(subquadrat = c("11", "12", "22"))
first_subquad_11

first_subquad_01 <- recode_subquad(first_subquad_11, offset = -1)
first_subquad_01

first_subquad_11 <- recode_subquad(first_subquad_01, offset = 1)
first_subquad_11

fgeo.tool documentation built on May 29, 2024, 5:30 a.m.