Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Arcsinh transform with a cofactor of 150 for Cytek Aurora data #42

Open
rohitfarmer opened this issue Sep 6, 2023 · 1 comment
Open

Comments

@rohitfarmer
Copy link

Hi there,

I am working with the spectral flow data from Cytek Aurora. I am trying to figure out how to specify a cofactor of 150 for arcsinh transformation in the transformList() function. Any suggestions would be helpful.

Thanks,
Rohit

@SamGG
Copy link

SamGG commented Sep 6, 2023

Hi,

My answer is not authoritative, Sofie or others will correct me.

transformList() is a flowCore function, so your question should be addressed to flowCore package. An even better place is the bioconductor support, because you don't report a bug in fact.

So, CytoNorm's readme shows the use of cytofTransf which is defined in CytoNorm. Its code could help you to set up your own transform. The code is below. NB: we also have to add a reverse transform. So functions for Cytek based on your choice is something like that:

cytekTransform <- flowCore::arcsinhTransform(transformationId="cytekTransform",
                                             a=0, b=(1/150), c=0)
cytofTransform.reverse <- function(x){
    return(sinh(x)*150)
}

We have to use the flowCore definition because this allows to the flwoCore infrastructure.

IMHO 150 is too low for Cytek, I would start with a cofactor of 3000 (e.g. Importing and Transforming Spectral Flow Cytometry Data in https://www.ncbi.nlm.nih.gov/pmc/articles/PMC8640183/)

Best,
Samuel

#' cytofTransform
#'
#' Arcsinh transformation with cofactor 5
#'
#' @param x Value to transform
#' @export
cytofTransform <- flowCore::arcsinhTransform(transformationId="cytofTransform",
                                             a=0, b=(1/5), c=0)

#' cytofTransform.reverse
#'
#' @param x Value to tranform
#' Function to reverse arcsinh transformation with cofactor 5
#'
#' @export
cytofTransform.reverse <- function(x){
    return(sinh(x)/(1/5))
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants