merge_gs: this is the wrapper for labkey where only one gslist to be...

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/pipeline.R View source: R/flowWorkspace-methods.R

Description

merge GatingSets based on the gating tree structures.

Sub-steps: 1. load the GatingSets parsed from step. 2 and does validity check to see if the gating trees within each gatingSet is clean try to resolve the discrepancy of gating trees within single GatingSet by dropping the extra terminal node for some samples (mistakenly added by the person who does flowJo) when there is non-leaf node causing the discrepancy, we throw the error to ask for human intervention such as: correct the typo of population name or drop the entire subtree 3. drop the redundant channels (since they are usually one of the causes for channel discrepancy across batches) 4. further drop the non-leaf nodes that cause the cross-batch discrepancy load parsed gs

Usage

1
2
3
merge_gs(output.dir)

merge_gs(output.dir)

Arguments

x

A list of GatingSets .

Details

Group the individual GatingSets by their gating schemes.It is done by comparing the node list returned by getNodes,which assumes they follow the same population naming conventions. Meanwhile the unused channels are automatically dropped to make sure the flow data has identical data structure within each group. In order to further merge multiple GatingSet objects into one, use rbind2.

Value

A GatingSetList that contains multiple GatingSets each of which share the same gating and data structure.

Author(s)

Mike Jiang wjiang2@fhcrc.org

See Also

rbind2,GatingSetList

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
	#load gatingsets from disk
	#gs_toMerge is the path that stores multiple archived gatingsets
	gs_list<-lapply(list.files("flowIncubator/output/gs_toMerge",full=T),function(this_folder){
      flowWorkspace:::load_gs(this_folder)
    })
    
	gs_list <- merge_gs(gs_list)
	gs_list
	

## End(Not run)

RGLab/flowIncubator documentation built on Sept. 5, 2020, 11:10 p.m.