Closed Chris8886 closed 4 years ago
@Chris8886, cyto_setup()
expects that the folder only contains valid FCS files, it does not explicitly check for this as some older files do not carry the FCS extension. It is on my list of things to improve, but for now you can tell it to ignore irrelevant files by passing the extensions to the exclude
argument:
gs <- cyto_setup("Samples",
exclude = ".csv")
@DillonHammill Solved, thank you!
I will update the logic in cyto_load()
so that any files with an extension that is not FCS
are excluded from the loading process.
@Chris8886, I just pushed an update to cyto_load()
to exclude files that do not contain a valid file extension by default. Hopefully this won't cause any problems. The only potential issue I can see is if a valid file lacks an FCS extension and the file name contains a dot, any text after the dot will be treated as the file extension (and hence the file will seem invalid). I think this is unlikely to occur and can be avoided with good file naming practices. If it becomes an issue I will think of a better solution. Please pull down the latest CytoExploreR (no need to update RGLab packages) and try loading in your files without using the exclude
argument:
devtools::install_github("DillonHammill/CytoExploreR")
# This should work now
gs <- cyto_setup("Samples")
Hey Dillon, Amazing job with the CytoExploreR!
Unfortunately, I've got a problem when using cyto_setup(). It is seems to work for me only when I'm using it for the first time in a given folder. So essentially, every time I close R I can't load my gs again because I get this error:
Loading FCS files into a GatingSet... Error in fcs_to_cytoset(sapply(files, normalizePath), list(which.lines = which.lines, : This does not seem to be a valid FCS2.0, FCS3.0 or FCS3.1 file
Deleting gating template and other csv files solves the problem.