Question: Modifying or writing a FCS file in R using the FlowCore package
gravatar for vonskopnik
14 months ago by
vonskopnik10 wrote:

Dear Community,

I am interest in how to modify of write a FCS file in R, in a way that I edit a flowframe and then save it to a FCS file. I think writing it from scratch is harder, so I would start with an existing file and modify it.

What I would like to do is to enter scRNAseq data into the FCS file so that I or others can explore the data with FlowJo as if it was data from flow cytometry. What I managed by myself is to modify the "exprs"-slot of the FCS file, save the FCS file and open it in FlowJo. In order to keep the file consistent (or correct) one has to modify the meta data as well (e.g. giving channel names and descriptions and so on). This appears rather tedious to me and it would probably take a bit of time to figure out the pitfalls of it.

I wonder if anyone could some code snippets for or a larger block of code to do this job. Alternatively, I am also happy to hear another approach of how to do this. Or, alternatively again, let me know if this idea does not make sense to you.


ADD COMMENTlink written 14 months ago by vonskopnik10

use flowFrame constructor

see example

You will need the latest Bioc devel or github trunk version of flowCore.

ADD REPLYlink written 14 months ago by Jiang, Mike1.2k

Great, that seems indeed to be rather useful.

Is it also possible to remove or add columns / channels completely?

ADD REPLYlink written 14 months ago by vonskopnik10

For an extensive example, take a look at the function cytof_addToFCS of cytofkit

ADD REPLYlink modified 14 months ago • written 14 months ago by SamGG190
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 385 users visited in the last hour