-
Notifications
You must be signed in to change notification settings - Fork 0
Cell attachment simulator
Joanna Pylvänäinen edited this page Oct 7, 2024
·
1 revision
Notebook used to simulates and compares cell attachment patterns on specific markers to determine if they occur by chance or exhibit a specific trend.
- Load the dataset by entering a file path or pasting tab-separated data.
- The dataset must include FOV, marker information, and cell counts.
- The results folder is created for output.
- Unzip the provided ZIP file containing FOV masks.
- Masks correspond to specific FOVs in the dataset and are used in the simulation.
- For each FOV, the corresponding binary mask is loaded.
- If a mask is missing, the analysis for that FOV is skipped.
- Cells are randomly placed in the FOV, and overlaps with markers are tracked.
- Simulations run 1,000 times to estimate random overlap distributions.
- The mean simulated overlaps are calculated for each FOV.
- The observed overlaps are compared to the simulated (random) overlaps to assess if the patterns differ from chance.
- Visualize the comparison using a combined dot plot and boxplot to show both observed and expected overlaps for each marker.
- The simulation results are saved as a CSV file for further analysis, containing observed and simulated overlap counts.
Notebook created by Guillaume Jacquemet