merge.quad.gates {ggcyto} | R Documentation

## extend the original flowWorkspace:::.mergeGates function to restore quadGate when applicable

### Description

For internal usage.

### Usage

    ## S3 method for class 'quad.gates'
    merge(gh, pops, bool = TRUE)

### Arguments

`gh` | a GatingHierarchy
`pops` | a vector of population names
`bool` | whether to deal with boolean gate

### Value

a nested list of data structure that captures the information of parent, grouped populations (with the same projections) and the reconstructed quadGate object and the respective quadrant pattern

### Examples

    library(flowWorkspace)
    dataDir <- system.file("extdata",package="flowWorkspaceData")
    gs <- load_gs(file.path(dataDir, "gs_manual"))
    #get the GatingHierarchy object
    gh <- gs[[1]]
    pops <- getChildren(gh, "CD4")
    grps  <- ggcyto:::merge.quad.gates(gh, pops)
    length(grps) # pops are grouped into two
    grps[[1]] # each group is annotaed with quadGate information

    ggcyto:::merge.quad.gates(gh, getChildren(gh, "CD3+")) # cd3 subsets are not coercible to quadgate thus return as they are

[Package ggcyto version 1.10.2 Index]