Skip to content

Possible to extract single cell-level gate memberships? #147

Answered by DillonHammill
hrj21 asked this question in Q&A
Discussion options

You must be logged in to vote

@hrj21, there isn't a nice CytoExploreR wrapper for this as of yet but you can have a look at gh_pop_get_indices() and gh_pop_get_indices_mat() from flowWorkspace. I will add a wrapper for the latter function which will return a logical vector for multiple populations at once. Here is an example using the Activation dataset shipped with CytoExploreRData:

library(CytoExploreRData)
gs <- GatingSet(Activation)
gs <- cyto_compensate(gs)
gs <- cyto_transform(gs)
gs <- cyto_gatingTemplate_apply(gs, Activation_gatingTemplate)

gh_pop_get_indices_mat(gs[[32]], c("T Cells", "CD4 T Cells", "CD8 T Cells"))

These APIs operate at the level of the GatingHierarchy so you will need to loop through the s…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@hrj21
Comment options

Answer selected by hrj21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants