BNGReference {osbng}R Documentation

BNG Reference objects

Description

Functions to support working with objects of type BNGReference.

Usage

## S3 method for class 'BNGReference'
x[i]

## S3 method for class 'BNGReference'
x[[i]]

## S3 replacement method for class 'BNGReference'
x[i] <- value

## S3 replacement method for class 'BNGReference'
x[[i]] <- value

## S3 method for class 'BNGReference'
c(...)

## S3 method for class 'BNGReference'
unique(x, incomparables = FALSE, ...)

## S3 method for class 'BNGReference'
as.data.frame(x, ...)

Arguments

x

Object of class BNGReference.

i

Record selection.

value

A suitable replacement value of type BNGReference.

...

Additional parameters.

incomparables

A vector of values that cannot be compared. See unique.

Details

The BNG is structured using a hierarchical system of grid squares at various resolutions. At its highest level, the grid is divided into 100 km by 100 km squares, each of which is identified by a two-letter code. Successive levels of resolution further subdivide the grid squares into finer detail, down to individual 1-meter squares.

Value

A vector of type BNGReference.

See Also

is_valid_bng(), as_bng_reference()

Examples

x <- as_bng_reference(c("TQ1234", "SU5678"))

x[1]

x[2] <- as_bng_reference("SU56")
x


[Package osbng version 0.2.0 Index]