View source: R/UpdateKlass-graph-navigate.R
klass_node | R Documentation |
Given a Klass graph, find the node corresponding to a code and (optionally) a date.
klass_node(graph, x, date = NA)
graph |
A graph generated by |
x |
The code to search for. |
date |
Optional. The specific date the supplied code is valid in. |
The node in the graph corresponding to the supplied code. If date is
not provided, the node with the most recent code is returned. If date is
provided, the code with date between validFrom
and validTo
is
returned.
# Build a graph directed towards the most recent codes.
library(klassR)
## Not run:
klass_131 <- klass_graph(131)
## End(Not run)
# Find the most recent node in the graph representing the code "0101" (Halden,
# valid to 2020.)
## Not run:
halden_node <- klass_node(klass_131, "0101")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.