Copy a node along with all of its descendant nodes to the given ancestor

gh_copy_gate(gh, node, to)

Arguments

gh

GatingHierarchy

node

the node to be copied

to

the new parent node under which the node will be copied

Examples

library(flowWorkspace) dataDir <- system.file("extdata",package="flowWorkspaceData") suppressMessages(gs <- load_gs(list.files(dataDir, pattern = "gs_manual",full = TRUE))) gh <- gs[[1]] old.parent <- gs_pop_get_parent(gh, "CD4") new.parent <- "singlets" gh_copy_gate(gh, "CD4", new.parent)
#> done!
#> [1] "root" #> [2] "/not debris" #> [3] "/not debris/singlets" #> [4] "/not debris/singlets/CD3+" #> [5] "/not debris/singlets/CD3+/CD4" #> [6] "/not debris/singlets/CD3+/CD4/38- DR+" #> [7] "/not debris/singlets/CD3+/CD4/38+ DR+" #> [8] "/not debris/singlets/CD3+/CD4/38+ DR-" #> [9] "/not debris/singlets/CD3+/CD4/38- DR-" #> [10] "/not debris/singlets/CD3+/CD4/CCR7- 45RA+" #> [11] "/not debris/singlets/CD3+/CD4/CCR7+ 45RA+" #> [12] "/not debris/singlets/CD3+/CD4/CCR7+ 45RA-" #> [13] "/not debris/singlets/CD3+/CD4/CCR7- 45RA-" #> [14] "/not debris/singlets/CD3+/CD8" #> [15] "/not debris/singlets/CD3+/CD8/38- DR+" #> [16] "/not debris/singlets/CD3+/CD8/38+ DR+" #> [17] "/not debris/singlets/CD3+/CD8/38+ DR-" #> [18] "/not debris/singlets/CD3+/CD8/38- DR-" #> [19] "/not debris/singlets/CD3+/CD8/CCR7- 45RA+" #> [20] "/not debris/singlets/CD3+/CD8/CCR7+ 45RA+" #> [21] "/not debris/singlets/CD3+/CD8/CCR7+ 45RA-" #> [22] "/not debris/singlets/CD3+/CD8/CCR7- 45RA-" #> [23] "/not debris/singlets/CD3+/DNT" #> [24] "/not debris/singlets/CD3+/DPT" #> [25] "/not debris/singlets/CD4" #> [26] "/not debris/singlets/CD4/38- DR+" #> [27] "/not debris/singlets/CD4/38+ DR+" #> [28] "/not debris/singlets/CD4/38+ DR-" #> [29] "/not debris/singlets/CD4/38- DR-" #> [30] "/not debris/singlets/CD4/CCR7- 45RA+" #> [31] "/not debris/singlets/CD4/CCR7+ 45RA+" #> [32] "/not debris/singlets/CD4/CCR7+ 45RA-" #> [33] "/not debris/singlets/CD4/CCR7- 45RA-"