Hi Gael,
Cytofkit should have created a subfolder in the output folder called "YourProjectName_analyzedFCS"
If you ran both tSNE and PhenoGraph using
cytofkit_GUI() then the FCS files in the "analyzedFCS" subfolder should have the tSNE coordinates and cluster IDs appended to the FCS file as additional columns. The parameters tsne_1_linear and tsne_2_linear are the X and Y coordinates of the tSNE plot generated by cytofkit, while Rphenograph_clusterIDs is the cluster IDs as integers. You can upload these files to Cytobank, view the data in tSNE space, and gate on it (tip: adjust the scales to make gating easier).
For example, here is a file (blahblahblah_ViableSinglets.fcs) from a recent analyzedFCS subfolder of mine. I loaded it into R using flowCore's
read.FCS() function, and then checked which parameters are present:
- Code:
> myfcs <- read.FCS("blahblahblah_ViableSinglets.fcs", transformation = FALSE)
> myfcs
flowFrame object 'blahblahblah_ViableSinglets.fcs'
with 2321 cells and 70 observables:
name desc range minRange maxRange
$P1 Time Time 3087428 0.00000000 3087428
$P2 Event_length Event_length 75 0.00000000 75
$P3 Y89Di 089Y_CD45 503 0.00000000 503
.... a bunch of markers ...
$P64 tsne_1 <NA> 3178 -0.08243132 3177
$P65 tsne_2 <NA> 3177 0.00000000 3176
$P66 tsne_1_linear <NA> 66 0.00000000 65
$P67 tsne_2_linear <NA> 73 0.00000000 72
$P68 Rphenograph_cor_1 <NA> 3175 -0.08145589 3174
$P69 Rphenograph_cor_2 <NA> 3178 -0.08237541 3177
$P70 Rphenograph_clusterIDs <NA> 14 0.00000000 13
654 keywords are stored in the 'description' slot
If you want to work in R, you can then plot the data in tSNE space with a color overlay. For example, here are some quick one-liners (not the prettiest plots):
- Code:
palette(rainbow(max(exprs(myfcs)[, "Rphenograph_clusterIDs"])))
plot(tsne_2_linear ~ tsne_1_linear, data=as.data.frame(exprs(myfcs)), col=Rphenograph_clusterIDs, pch=16, main=description(myfcs)$GUID)
or
- Code:
plot(tsne_2_linear ~ tsne_1_linear, data=as.data.frame(exprs(myfcs)), col=(asinh((Y89Di)/5)), pch=16, main=description(myfcs)$GUID)
You mentioned that in your workflow, you first performed viSNE in Cytobank, then used Cytofkit to run PhenoGraph. That's the reverse strategy of what I proposed above, but it's fine too. If you export the FCS files from Cytobank's viSNE experiment, I believe it will include parameters named tSNE1 and tSNE2 appended to the FCS file. In that case, just skip the tSNE step in cytofkit (i.e. only run PhenoGraph) when you use these files for PhenoGraph. Be sure to include all events for clustering (don't use ciel or max). When PhenoGraph finishes, upload the clustered FCS files from the analyzedFCS folder to Cytobank. You can then use Cytobank's original tSNE1 and tSNE2 parameters to view the data, and view the Rphenograph_clusterIDs parameter as a color in the Z parameter.
You've got options. Good luck!
ES