flowCore: uneven number of tokens / The last keyword is dropped.
1
0
Entering edit mode
OT • 0
@ot-9575
Last seen 4.0 years ago
Germany

Dear all,

we have a new Attune flow cytometer. The resulting FCS files produce a warning message when read in via flowCore, regardless of whether the export from the software is performed as FCS3.0 or FCS3.1. Successful import is only possible when specifying emptyValue = FALSE in the call to read.FCS. Even so, a complaint is raised about an uneven number of tokens and the last keyword being dropped (see below). While this does not (as far as I noticed) impact the downstream analysis in any way, it pollutes the output quite severely when reading in samples from a full plate. I am happy to provide an example FCS file by mail, but I do not see a way to upload an attachment.

Thank you!

> library(flowCore)
> 
> read.FCS("test.fcs")
Error in fcsTextParse(txt, emptyValue = emptyValue) : 
  Empty keyword name detected!If it is due to the double delimiters in keyword value, please set emptyValue to FALSE and try again!
>
> read.FCS("test.fcs", emptyValue=FALSE)
uneven number of tokens: 333
The last keyword is dropped.
uneven number of tokens: 333
The last keyword is dropped.
flowFrame object 'test.fcs'
with 27776 cells and 13 observables:
      name   desc    range minRange maxRange
$P1   Time   Time 67108864        0 67108863
$P2  FSC-A  FSC-A  1048576        0  1048575
$P3  SSC-A  SSC-A  1048576     -111  1048575
$P4  BL1-A FITC-A  1048576     -111  1048575
$P5  RL1-A  DiD-A  1048576     -111  1048575
$P6  VL1-A Auto-A  1048576     -111  1048575
$P7  FSC-H  FSC-H  1048576        0  1048575
$P8  SSC-H  SSC-H  1048576        0  1048575
$P9  BL1-H FITC-H  1048576        0  1048575
$P10 RL1-H  DiD-H  1048576        0  1048575
$P11 VL1-H Auto-H  1048576        0  1048575
$P12 FSC-W  FSC-W     1024        0     1023
$P13 SSC-W  SSC-W     1024        0     1023
196 keywords are stored in the 'description' slot
flowCore • 2.7k views
ADD COMMENT
0
Entering edit mode
suppressWarnings(read.FCS("test.fcs", emptyValue=FALSE))
ADD REPLY
0
Entering edit mode

Thank you for the suggestion. suppressWarnings() doesn't do it here, because these aren't actually warnings, but sink("/dev/null") takes cares of it.

ADD REPLY
1
Entering edit mode
SamGG ▴ 360
@samgg-6428
Last seen 13 hours ago
France/Marseille/Inserm

Hi, This warning arises usually when the file dos not comply to the FCS standard. You could check the compliance with http://bioinformin.cesnet.cz/flowIO/ (flowIO, CLIP, Prague) or https://primitybio.github.io/fcs-validator/ (Zach Bjornson). More on such error in problems with fcs 3.1 files exported from Macsquantify. Best.

ADD COMMENT
0
Entering edit mode

(empty comment, sorry)

ADD REPLY
0
Entering edit mode

Dear @SamGG, thanks for this wonderful web validators! Are there any R package that can perform this validation but via terminal without web needed?

Thanks again!

ADD REPLY
0
Entering edit mode

Hi,

Zach's solution is pure Javascript.

flowIO is R based. The source code is available at https://bitbucket.org/Mira_Koblizek/flowio/src/master/

The Shiny application is based on functions that are available separately (see the R folder). There is a R markdown script that seems to check every parts of the FCS. So you can get easily a nicely formatted document. The shiny app sounds to refer to this Rmd file for the reporting. The interactive part of flowIO concerns mainly changing values. https://bitbucket.org/MiraKoblizek/flowio/src/master/inst/shiny/app.R https://bitbucket.org/MiraKoblizek/flowio/src/master/inst/shiny/checks.Rmd

Thanks to those authors for this interesting application and for having designed it wisely. Contact them directly to get more information/feedback. Please share your developments with the community.

Best.

ADD REPLY

Login before adding your answer.

Traffic: 653 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6