Question: Flow cytometry optimization of transformation parameters
0
gravatar for carlos.x.martinez-fleites
8 days ago by

Hello,

I would like to optimise the parameters for an arcsinh transformation of flow cytometry data. I can optimise logicle parameters per channel as:

best_parameters <- estimateLogicle(frame, channels = channels, type = "data")

and then apply transformation as:

best_transformation <- transform(frame, best_parameters)

the closest equivalent I could find for arcsinh transformation is:

flowTrans(frame, "mclMultivArcSinh",colnames(frame)[channels], n2f=FALSE, parameters.only=TRUE)

but this only produces one set of parameters, a, b, c and not a set of parameters per channel.

Is it possible to produce optimised arcsinh parameters per channel at all? is it correct to expect them?

Any clarification will be welcome.

Many thanks.

ADD COMMENTlink written 8 days ago by carlos.x.martinez-fleites0

Hi Carlos,

I think there are two points in your question.

a) estimating the best set of parameters for a asinh transform: I don't know how to achieve this. Probably Mike and Greg do.

b) looping across the channels: you could find the code of the estimateLogicle function at https://github.com/RGLab/flowCore/blob/fbe2a3d1f18acff6d3967d1e8488d7ccc322d95d/R/AllClasses.R#L5103 and try to derivate a simple loop.

Best.

ADD REPLYlink written 8 days ago by SamGG180
1

Or you can merge all of your fcs files to get a better estimate of the transformation parameters

fs_merge <- flowFrame(fsApply(fset, exprs))
trans <- estimateLogicle(fs_merge, chnls)

# apply transformation to your flowSet
fset <- trans %on% fset
ADD REPLYlink written 7 days ago by mikhael.manurung30

I agree totally. The parameters of the transformation should be the same for all the samples aka FCS. So pooling all FCS before estimating logicle is definitively what should be done within a batch, unless you have good reasons to do an estimation file by file. IIRC there is an alternative way to convert a flowSet to a flowFrame : fs_merge <- as(fset, "flowFrame") Best

ADD REPLYlink written 7 days ago by SamGG180

Hi SamGG and Mikhael,

thank you very much for your replies, I agree that pooling all data to estimate parameters seems a better idea that selecting a single frame, i will implement this suggestion.

I will also try to implement looping through channels for the arcsinh estimation if there isn't an immediate solution.

Best regards,

Carlos

ADD REPLYlink written 7 days ago by carlos.x.martinez-fleites0

Thanks for your reply. Let us know about your feedback and if you could publish your code, it could be helpful for the community. Best.

ADD REPLYlink written 7 days ago by SamGG180
Please log in to add an answer.

Help
Access

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