View source: R/map_utilities.R
order_maps | R Documentation |
Sort a list of mappings so that the sequential application of the mappings yields the correct result.
order_maps(maps)
maps |
List of mapping objects, e.g., as obtained by |
Mappings whose source indices contain target indices of another mapping must not be applied before that mapping. This function puts the mappings into an order to ensure this criterion is met.
Return a list with the ordered maps
params1 <- list( mapname = "mylinearmap1", maptype = "linearinterpol_map", src_idx = 1:3, tar_idx = 4:6, src_x = c(1,5,10), tar_x = c(4,5,6) ) params2 <- list( mapname = "mylinearmap2", maptype = "linearinterpol_map", src_idx = 4:6, tar_idx = 7:9, src_x = c(4,5,7), tar_x = c(4.5, 5, 5.5) ) mymap1 <- create_map(params1) mymap2 <- create_map(params2) ordmaps <- order_maps(list(mymap2, mymap1)) lapply(ordmaps, function(x) x$getName())
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.