**0**wrote:

I have noticed that gates defined using transformations (via the %on% operator) and boolean operations (!, &, |, %&%) are not supported by flowCore's GatingSet and by ggcyto. E.g.

library(flowCore) library(ggcyto) fcsSet <- read.flowSet(path=system.file("extdata", "compdata", "data", package="flowCore")) myTransform <- transform("FSC-H" = log, "SSC-H" = log) mat <- matrix(c(500, 400, 400, 600, 650, 650, 500, 600, 750, 750, 600, 500), nrow = 6) colnames(mat) <- c("FSC-H", "SSC-H") myGate <- polygonGate(log(mat)) %on% myTransform # Subset is happy: nrow(Subset(fcsSet[[1]], myGate)) # [1] 10 gateSet <- GatingSet(fcsSet) add(gateSet, myGate) # replicating filter 'defaultPolygonGate on transformed values of FSC-H,SSC-H' across samples! # Error in (function (classes, fdef, mtable) : # unable to find an inherited method for function ‘filterObject’ for signature ‘"transformFilter"’ # not run: # recompute(gateSet) # autoplot(gateSet, "defaultPolygonGate") recompute(gateSet) autoplot(fcsSet[[1]], "FSC-H", "SSC-H") + geom_gate(myGate) # Error: ggcyto doesn't know how to deal with gate of class transformFilter

Am I missing something here or is there an alternative workflow? (In the example above, one could perhaps transform the parameters first and then do the gating, but this approach wouldn't help if different transformations are used by different gates or in cases of combinatorial gates).

**1.2k**• written 2.1 years ago by jaera •

**0**