set_graph_time {DiagrammeR} | R Documentation |
Set the time and timezone for a graph object of class
dgr_graph
.
set_graph_time(graph, time = NULL, tz = NULL)
graph |
a graph object of class |
time |
the date-time to set for the graph. |
tz |
the timezone to set for the graph. |
a graph object of class dgr_graph
.
## Not run: # Create an empty graph graph <- create_graph() # Provide the new graph with a timestamp (if `tz` not supplied, # `GMT` is used as the time zone) graph_1 <- set_graph_time(graph, time = "2015-10-25 15:23:00") # Provide the new graph with a timestamp that is the current # time; the time zone is inferred from the user's locale graph_2 <- set_graph_time(graph) # The time zone can be updated when a timestamp is present graph_2 <- set_graph_time(graph_2, tz = "America/Los_Angeles") ## End(Not run)