Giter Club home page Giter Club logo

Comments (4)

tlnagy avatar tlnagy commented on June 14, 2024

Can you send me a FCS file (either upload to this issue or via email) that causes this error?

(text_mappings["\$DATATYPE"] != "F") && error("Non float32 support not implemented yet. Please see github issues for this project.")

It looks like I only implemented support for reading Float32 values for the $DataType. From the spec it looks like there are 4 options:

This keyword describes the type of data written in the DATA segment of the data set. The four
allowed values are 'I', 'F', 'D', or 'A'. The DATA segment is a continuous bit stream with no
delimiters. 'I' stands for unsigned binary integer, F stands for single precision IEEE floating point,
'D' stands for double precision IEEE floating point, and 'A' stands for ASCII. The additional
keywords $PnB (bits per parameter) and $PnR (range per parameter) are needed to completely
describe an event in the DATA segment.

It doesn't appear to be too difficult to add support for these other datatypes.

from fcsfiles.jl.

ljamesherald avatar ljamesherald commented on June 14, 2024

Sure thing, here is a link to the .fcs file. Unfortunately, GitHub doesn't allow for .fcs files to be uploaded directly.
https://drive.google.com/file/d/1AixgKRw6nFqAmjK9um1AR0mrDg83wiOO/view?usp=sharing

from fcsfiles.jl.

tlnagy avatar tlnagy commented on June 14, 2024

It looks like your file stores data as an unsigned binary integer (I) , which is not currently implemented.

I can add this feature, but I would also be happy to review and merge a PR if you want to add support. The relevant function is linked to in my previous comment. It doesn't look too difficult to do, here's the relevant section in the spec:

$DATATYPE/I/ means that the events are written as unsigned binary integers. For each
parameter in an event, both the maximum length in bits allocated for storage of the parameter
and the actual integer range used by the parameter within that allocation are needed. The
number of bits per parameter is specified by $PnB. For example, $P1B/16/ specifies that 16 bits
are allocated for parameter 1. $P1R/1024/ specifies that parameter 1 values range from 0 to
1023. This allows the data word length to be specified, facilitating compatibility between machines
with different data word lengths and enabling bit compression of the data.

from fcsfiles.jl.

tlnagy avatar tlnagy commented on June 14, 2024

Here's a dump of all the parameters from your FCS file:

 "\$P7G" => "1.0000000000"
 "\$BEGINANALYSIS" => "00000000000000"
 "\$BTIM" => "10:21:18"
 "\$P4S" => "488-FSC"
 "\$ENDSTEXT" => "00000000000000"
 "\$P4N" => "FSC1-Area"
 "\$TIMESTEP" => "0.0000000100"
 "\$FIL" => "D:\\Data\\Alberts\\Apr 23 2014\\U DMSO.fcs"
 "\$P7F" => "SSC"
 "\$P2R" => "4294967296"
 "\$P6S" => "488-SSC"
 "\$P8V" => "297.0000000000"
 "\$P1E" => "0.0,0.0"
 "\$P1G" => "1.0000000000"
 "\$P2G" => "1.0000000000"
 "\$PAR" => "10"
 "\$P4R" => "4294967296"
 "\$P4L" => "488.0000000000"
 "\$P10P" => "0"
 "\$P9G" => "1.0000000000"
 "\$P8G" => "1.0000000000"
 "\$P2P" => "0"
 "\$SMNO" => "2"
 "\$P10E" => "0.0,0.0"
 "\$P10B" => "32"
 "\$P9N" => "FL11-Height"
 "\$P6V" => "297.0000000000"
 "\$P3E" => "0.0,0.0"
 "\$P10F" => "576/21"
 "\$P3S" => "488-FSC"
 "\$P2B" => "32"
 "\$P2S" => "Time MSW"
 "\$P5B" => "32"
 "\$P5S" => "488-FSC"
 "\$P7L" => "488.0000000000"
 "\$LOST" => "0"
 "\$P5E" => "0.0,0.0"
 "\$DATE" => "23 Apr 2014"
 "\$P7N" => "SSC1-Area"
 "\$TR" => "SSC1-Height,65535"
 "\$P3L" => "488.0000000000"
 "\$NEXTDATA" => "00000000000000"
 "\$P1P" => "0"
 "\$P3N" => "FSC1-Height"
 "\$P2N" => "TIME2"
 "\$P4F" => "FSC"
 "\$P3B" => "32"
 "\$P10N" => "FL12-Height"
 "\$ETIM" => "10:22:34"
 "\$P5G" => "6.0000000000"
 "\$P9S" => "DiO 488-513/26"
 "\$P1S" => "Time LSW"
 "\$P7V" => "297.0000000000"
 "\$P4G" => "1.0000000000"
 "\$P8N" => "SSC1-Width"
 "\$P6P" => "0"
 "\$P9E" => "0.0,0.0"
 "\$P6L" => "488.0000000000"
 "\$P9V" => "378.0000000000"
 "\$P6B" => "32"
 "\$P9P" => "0"
 "\$P3F" => "FSC"
 "\$P10G" => "1.0000000000"
 "\$SYS" => "Summit V6.2.3.15613 Released Version / Windows NT Version 6.1 / Intel Processor"
 "\$P5F" => "FSC"
 "\$P5N" => "FSC1-Width"
 "\$P6N" => "SSC1-Height"
 "\$P2E" => "0.0,0.0"
 "\$P8E" => "0.0,0.0"
 "\$TOT" => "24599"
 "\$P1B" => "32"
 "\$P8F" => "SSC"
 "\$OP" => "MoFlo Astrios"
 "\$P6F" => "SSC"
 "\$P1N" => "TIME"
 "\$P4B" => "32"
 "\$P7S" => "488-SSC"
 "\$P7R" => "4294967296"
 "\$P7E" => "0.0,0.0"
 "\$P8R" => "4294967296"
 "\$P8P" => "0"
 "\$ENDANALYSIS" => "00000000000000"
 "\$P10L" => "488.0000000000"
 "\$P4P" => "0"
 "\$P4V" => "0.0000000000"
 "\$SRC" => " "
 "\$P8B" => "32"
 "\$CYT" => "MoFlo Astrios"
 "\$SPILLOVER" => "2,9,10,1.000000,0.223429,0.028000,1.000000"
 "\$P3P" => "0"
 "\$P5R" => "4294967296"
 "\$P3G" => "6.0000000000"
 "\$P3V" => "0.0000000000"
 "\$P5L" => "488.0000000000"
 "\$P6E" => "0.0,0.0"
 "\$P7B" => "32"
 "\$INST" => "Institution"
 "\$P10R" => "4294967296"
 "\$P8S" => "488-SSC"
 "\$P9B" => "32"
 "\$P1R" => "4294967296"
 "\$PROJ" => "Project"
 "\$P10S" => "DiI 488-576/21"
 "\$P5V" => "0.0000000000"
 "\$P6R" => "4294967296"
 "\$ENDDATA" => "00000000988055"
 "\$BYTEORD" => "1,2,3,4"
 "\$P10V" => "373.0000000000"
 "\$DATATYPE" => "I"
 "\$P8L" => "488.0000000000"
 "\$BEGINSTEXT" => "00000000000000"
 "\$P4E" => "0.0,0.0"
 "\$P9R" => "4294967296"
 "\$P9F" => "513/26"
 "\$P6G" => "1.0000000000"
 "\$BEGINDATA" => "00000000004096"
 "\$P5P" => "0"
 "\$P7P" => "0"
 "\$P9L" => "488.0000000000"
 "\$P3R" => "4294967296"
 "\$MODE" => "L"

from fcsfiles.jl.

Related Issues (5)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.