{"id":23656276,"url":"https://github.com/hannahgsimon/halmodeling2024graphs","last_synced_at":"2025-11-23T09:30:15.961Z","repository":{"id":251281217,"uuid":"836947489","full_name":"hannahgsimon/HALModeling2024Graphs","owner":"hannahgsimon","description":"Created code to develop and analyze statistical graphs for the spatial radiotherapy model, which can be found at https://github.com/hannahgsimon/HALModeling2024. This project was in association with the Cleveland Clinic Lerner Research Institute, Jacob Scott Lab.","archived":false,"fork":false,"pushed_at":"2025-01-10T20:40:45.000Z","size":41,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-10T21:41:57.821Z","etag":null,"topics":["agent-based-model","bifurcation-analysis","cancer-models","computational-biology","data-visualization","hybrid-automata","immune-response","mathematical-modelling","ordinary-differential-equations","radiation-therapy","spatial-model","statistics","systems-biology"],"latest_commit_sha":null,"homepage":"https://www.lerner.ccf.org/translational-hematology-oncology/scott/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hannahgsimon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-01T22:27:02.000Z","updated_at":"2025-01-10T20:40:48.000Z","dependencies_parsed_at":"2024-11-01T23:16:41.640Z","dependency_job_id":"dbe12819-6ae7-4250-abee-fb07d4ace061","html_url":"https://github.com/hannahgsimon/HALModeling2024Graphs","commit_stats":null,"previous_names":["hannahgsimon/halmodeling2024graphs"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hannahgsimon%2FHALModeling2024Graphs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hannahgsimon%2FHALModeling2024Graphs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hannahgsimon%2FHALModeling2024Graphs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hannahgsimon%2FHALModeling2024Graphs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hannahgsimon","download_url":"https://codeload.github.com/hannahgsimon/HALModeling2024Graphs/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239627235,"owners_count":19670844,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agent-based-model","bifurcation-analysis","cancer-models","computational-biology","data-visualization","hybrid-automata","immune-response","mathematical-modelling","ordinary-differential-equations","radiation-therapy","spatial-model","statistics","systems-biology"],"created_at":"2024-12-28T20:19:08.651Z","updated_at":"2025-11-23T09:30:15.875Z","avatar_url":"https://github.com/hannahgsimon.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# HALModeling2024Graphs\n\n## Overview\nThe HALModeling2024Graphs repository contains Python scripts to generate and analyze graphs for the HALModeling2024 project, found at https://github.com/hannahgsimon/HALModeling2024. This code graphs cell population changes in response to radiotherapy, as well as the immune response.\n\n## Prerequisites\n- **Python**: Version 3.6 or higher.\n- **Required Python packages**: You can install them using `pip`:\n   ```bash\n   pip install pandas matplotlib\n\n## Installation\n1. Clone the repository:\n    - git clone https://github.com/hannahgsimon/HALModeling2024Graphs.git\n2. Navigate to the project directory with the cd command.\n3. Import the project into your preferred Python IDE.\n4. Build the project.\n\n## Features\n- **\u003cins\u003ePlot Trial Cell Populations\u003c/ins\u003e:** Plots cell counts at each timestep for the last trial.\n- **\u003cins\u003ePlot Trial Immune Response\u003c/ins\u003e:** Plots the total immune response, primary immune response, and secondary immune response at each timestep.\n- **\u003cins\u003ePlot Scenario Cell Populations with Confidence Intervals\u003c/ins\u003e:** For the indicated scenario, plots the average cell counts with confidence intervals (±1 SD) at each timestep across all trials. For scenarios C, D, and E, will only plot trials with initial escape \u0026 radiation.\n- **\u003cins\u003ePlot Tumor Cells at Equilibrium\u003c/ins\u003e:** For trials in which bifurcation to escape occurred, plots a box and whisker plot of the number of tumor cells at equilibrium across each scenario.\n- **\u003cins\u003ePlot Timesteps to Equilibrium\u003c/ins\u003e:** For trials in which bifurcation to escape occurred, plots a box and whisker plot of the number of timesteps to equilibrium across each scenario.\n\n## Usage\nBefore running the code, you will need to update the file paths.  \nIn `HALModeling2024Graphs.py`:  \n  ```python\n  file_path = r'C:\\Users\\Hannah\\Documents\\HALModeling2024Outs\\TrialRunCounts.csv'\n  folder_path = fr'C:\\Users\\Hannah\\Documents\\HALModeling2024Outs\\Scenario{scenario}\\*.csv'\n  file_path = fr'C:\\Users\\Hannah\\Documents\\HALModeling2024Outs\\Scenario{scenario}\\*.csv'\n  save_path = fr'C:\\Users\\Hannah\\Documents\\HALModeling2024Outs\\TrialRunGraphScenario{scenario}.png'\n  save_path = r'C:\\Users\\Hannah\\Documents\\HALModeling2024Outs\\TrialRunGraphImmuneResponse.png'\n   ```\nIn `HALModeling2024Plots.py`:  \n  ```python\n  file_path = r'C:\\Users\\Hannah\\Documents\\HALModeling2024Outs\\AvgTimestepstoEscape.csv'\n  timesteps_save_path = fr'C:\\Users\\Hannah\\Documents\\HALModeling2024Outs\\BoxplotTimesteps.png'\n  tumorcells_save_path = fr'C:\\Users\\Hannah\\Documents\\HALModeling2024Outs\\BoxplotTumorCells.png'\n  ```\n##### Usage in `HALModeling2024Graphs.py`:\n- Input 1: `TrialRunCounts.csv` — Contains data from the final trial (non-scenario-specific), generated when `printCounts = true` and `scenarioActive = false` in `OnLattice2DGrid.java`.\n- Input 2: A folder containing trials for a specific scenario, generated when `printCounts = true` and `scenarioActive = true` in `OnLattice2DGrid.java`.\n\nThe simulation starts with the below initial conditions (modifiable in the code). You can update these parameters in the indicated lines of code to fit your specific simulation requirements.\n- **\u003cins\u003ePlot with Confidence Intervals\u003c/ins\u003e:** Disabled. For the indicated scenario, plots the average cell counts with confidence intervals (±1 SD) at each timestep across all trials. For scenarios C, D, and E, will only plot trials with initial escape \u0026 radiation.\n     ```python\n    plot_with_CIs = False\n     ```\n- **\u003cins\u003eScenario Analysis\u003c/ins\u003e:** Disabled. For the last trial of the indicated scenario, plots the cell counts at each timestep.\n     ```python\n     scenarioAnalysis = False\n     ```\n- **\u003cins\u003eScenario\u003c/ins\u003e:** A. The indicated scenario that will be graphed for `plot_with_CIs = True` or `scenarioAnalysis = True`.\n     ```python\n    scenario = 'A'\n     ```\n- **\u003cins\u003eTimesteps 500\u003c/ins\u003e:** Enabled. For `plot_with_CIs = True`, only the first 500 timesteps are plotted.  In the original `OnLattice2DGrid.java` code, this corresponds to the time by which the triggering cell population typically reaches 0. This occurs because there are initially 500 triggering cells, with 1 removed per timestep; however, the population may reach 0 sooner if cells are killed by radiation.\n     ```python\n    timesteps500 = True\n     ```\n- **\u003cins\u003ePlot Immune Response\u003c/ins\u003e:** Enabled. Plots the total immune response, primary immune response, and secondary immune response at each timestep. If `scenarioAnalysis = True`, plots the data for the last trial of the indicated scenario. If `scenarioAnalysis = False`, plots the data for the last trial (titled `TrialRunCounts.csv`, not a specific scenario).\n     ```python\n    graph_immune = True\n     ```\n- Note: When both `plot_with_CIs = False` and `scenarioAnalysis = False`, plots cell counts at each timestep for the last trial (`TrialRunCounts.csv`, not tied to a specific scenario).\n\n#### Usage in `HALModeling2024Plots.py`:\n- Input: A CSV file with 5 columns: \"Scenario\", \"Trial\" number, \"Bifurcation to Escape\" (Y/N), \"Timesteps to Equilibrium\", and \"Tumor Cells at Equilibrium\". The last 2 columns are blank for non-escape trials.\n- Output 1: For trials in which bifurcation to escape occurred, plots a box and whisker plot of the number of tumor cells at equilibrium across each scenario.\n- Output 2: For trials in which bifurcation to escape occurred, plots a box and whisker plot of the number of timesteps to equilibrium across each scenario.\n\n## Contributing\nContributions are welcome! To contribute:\n1. Fork the repository.\n2. Create a new branch for your feature or bug fix:\n    - git checkout -b feature-name\n3. Commit your changes and push the branch:\n    - git commit -m \"Add new feature\"\n    - git push origin feature-name\n4. Open a pull request and describe your changes in detail.\n\n## License\nThis project is licensed under the MIT License. See the LICENSE file for details.\n\n## Contact\nFor questions or feedback, please contact Hannah G. Simon at hgsimon2@gmail.com.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhannahgsimon%2Fhalmodeling2024graphs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhannahgsimon%2Fhalmodeling2024graphs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhannahgsimon%2Fhalmodeling2024graphs/lists"}