print.BNGReference {osbng} | R Documentation |
Printing BNG References
Description
Supporting formatting and printing of BNGReference
objects.
Usage
## S3 method for class 'BNGReference'
print(x, ...)
## S3 method for class 'BNGReference'
format(x, compact = FALSE, ...)
Arguments
x |
An object of type |
... |
Additional parameters. |
compact |
Logical. Should standard spaces be added or removed for
"pretty" printing? Default is |
Details
Standard spaces are added: 1) after the two-letter prefix, 2) between eastings and northings, and 3) before a quadrant suffix, when those components exist in a grid reference.
Value
-
format
provides a standard formatting of BNG reference objects -
print
outputs the BNG references and invisibly returns the object.
Examples
x <- as_bng_reference("SU1234")
print(x)
print(x, compact = TRUE)
[Package osbng version 0.2.0 Index]