Zebrafish Embryonic Photomotor Response

The Embryonic Photomotor Response (EPMR) assay quantifies larval motion using the Activity Metric.

Data Handling and Reanalysis

When you run the EPMR assay, the EPMR analysis always runs on the raw, uncompressed data as it is captured. To reanalyze a dataset later, you compress it and run the activity-metric analysis on the compressed .mp4. How you choose to save the source data does not affect this — base that decision on your own needs, whether that is higher-quality imagery or smaller data storage.

What happens while the assay runs. The EPMR analysis runs on the captured data and writes the original results.csv. The raw mcam_dataset.nc is an optional lossless copy, and compressing to dataset.mp4 is what makes later reanalysis possible.

        flowchart LR
    C[Captured data]
    C --> E[EPMR analysis]
    E --> R1["results.csv<br/><small>Original results</small>"]
    C --> NC["mcam_dataset.nc<br/><small>Raw · lossless · optional</small>"]
    C --> K[Compress]
    K --> V["dataset.mp4<br/><small>Compressed · lossy</small>"]

    classDef green stroke:#2da44e,stroke-width:2px;
    classDef amber stroke:#bf8700,stroke-width:2px;
    classDef blue stroke:#0969da,stroke-width:2px;
    class R1 green;
    class NC blue;
    class V amber;
    

Re-running activity analysis later reads the saved dataset.mp4 and runs the activity analysis on it to produce a fresh results.csv.

        flowchart LR
    V["dataset.mp4"] --> RD[Read] --> AA[Activity analysis] --> R2["results.csv<br/><small>Will differ from original</small>"]

    classDef amber stroke:#bf8700,stroke-width:2px;
    class V,R2 amber;
    

Warning

Reanalysis will not reproduce the original results.

MP4 compression is lossy — it alters the pixel values the activity analysis relies on. Reanalyzing the compressed video therefore produces different numbers than the original EPMR analysis of the uncompressed data. See Image and Video Storage Formats for how compression affects pixel data.

Tip

Recommended workflow

If you expect to reanalyze, treat the compressed-data analysis as your reference (“true”) results — it is the only output you can reproduce later from the saved .mp4. When the drive has room, also archive the raw .nc as a higher-quality copy — you can always recompress it later if needed. Reporting from the compressed analysis keeps your baseline and any future reanalysis consistent.