compute_eigen_centr_period_window <- function(.graph,
.year_start, .year_end,
.only_active_places = T,
.years_to_lower_boundary){
graph.eigen <- .graph %>%
tidygraph::as_tbl_graph() %>%
tidygraph::mutate(name = as.integer(name))
years <- seq(.year_start, .year_end, 1)
for(i in 1:length(years)){
df <- compute_centr_year(.graph,
.yr_centr_computed = years[i],
.lower_boundary_yr = years[i] - .years_to_lower_boundary,
.only_active_place = .only_active_places)
graph.eigen <- graph.eigen %>%
tidygraph::activate(nodes) %>%
tidygraph::left_join(df, by = "name")
}
return(graph.eigen)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.