I've successfully created a gate with
.singletGate and added it to a gate set with
However I could not do the same thing for a
Here is the code I used for both gates:
ncfs <- read.ncdfFlowSet(fcsFiles, alter.names=TRUE, transformation=FALSE, truncate_max_range=FALSE) ncfs #create gating element gs <- GatingSet(ncfs) #look at one of the frames fr <- ncfs[] #make a first gate with a singleGate chnl <- c("Parameter_13", "Parameter_11") gate1 <- openCyto:::.singletGate(fr, channels = chnl, filterId = "singlet") #look at the current gating paths gs_get_pop_paths(gs) #Add gate1 gs_pop_add(gs, gate1, parent = "root") #look at the gates again gs_get_pop_paths(gs) #Compute population in gate recompute(gs, "singlet")
#This part worked fine, and the gate was added to gs successfully.
#make another gate with a quadGate chnl <- c("Parameter_13", "Parameter_11") gate2 <- openCyto:::.quadGate.tmix(fr, channels = chnl, K = 4, usePrior = "no", filterId = "quad") #look at the current gating paths gs_get_pop_paths(gs) #Add gate2 to root gs_pop_add(gs, gate2, parent = "root")
The error message is:
Error in gs_pop_add(gs, gate2, parent = "root") :
names of gate list do not match with the sample names in the gating set!
Aren't the sample names suppose to be identical because the gate was built based on
fr which is derived from the same set as