Generate Dose-Response Curves
Project description
py50: Generate Dose-Response Curves
Summary
The aim of py50 is to make the generation of dose-respnose curves and annotated plots with statistics. The project was created primarily for my personal use and for my coworkers/classmates. I found many of my classmates/coworkers were using a program that I find to be unfriendly in generating dose-response curves or with calculating statistics and plots. During my search, I found other helpful repositories that can generate dose-response curves, calculate statistics, or make annotated plots. However, I found that these packages did not meet my requirements:
- Use Pandas for the Data so that it can be easily plugged into a Jupyter Notebook or Python scripts
- Adaptable to user needs
- Easy to use (hopefully!)
The dose-response curves are built on the four parameter logistic regression model: $$Y = \text{Min} + \frac{\text{Max} - \text{Min}}{1 + \left(\frac{X}{\text{IC50}}\right)^{\text{Hill coefficient}}}$$ where min is the minimum response value, max is the maximum response value, Y is the response values of the curves, X is the concentration.
The statistics and annotated plots is a wrapper for Pingouin and Statannotations. This may have been done inelegantly and will be updated based on my use or recommendations by other users. As things stand, this project meets my and the needs of my classmates/coworkers. Hopefully it can meet the needs of others.
Installation
pip install py50
Pacakge can be upgraded specifically using pip with the following:
pip install py50 -U
Warning: As of this writing, Statannotations is at v0.6. It is incompatible with Seaborn ≥v0.12 or with Pandas ≥v.2.0. During testing, I found that Seaborn v0.12.2 had no issues. This is advantages because v0.12 allows better control of error bars for the bar plot. Unfortunately, the python packaging system I use, Poetry, will not successfully build if there are conflicts. Thus, the py50 installation will install Seaborn v0.11.2 instead. As written, py50 will not work with bar plots for Seaborn ≤ v0.12.0. I recommend manually installing Seaborn v0.12.2 manually afterward using:
pip install seaborn==0.12.2
I would love contribute to the main Statannotations branch and bump it up to match the Seaborn updates, but it seems to be a daunting challenge and will require time on my part. 🤞Hopefully the main maintainers and contributors can get to it sooner!🤞
Tutorial
Documentation can be found here.
A Jupyter Notebook demoing the code can be found here.
A blog post demoing the code can be found at Practice in Code
Web Application
For those who are not versed in python coding, py50 has been converted into a web application using Streamlit!
The web application can be found here: py50-app
The repository for the Streamlit app version can be found here: py50-streamlit
NOTE: Updates to the web application take more time. As of this writing, the py50 Streamlit is running on version 0.3.6. Updates with statistics and plot annotations will be forthcoming.
Future Work
With the release of py50 v1.0.0, I have finished a project that has been on my mind for the past six months. My aim now will be to reformat the code for maintainability and to fix any bugs that I find or others report. I plan on maintaining py50 for the foreseeable future. As such, my current "To-Do" list (in no particular order) are as follows:
- Complete To-Do notes in Python script
- Update Tutorials for clarity
- Update py50 Streamlit to version 1.0.0
- Refactor code for maintainability
- Add error messages!
- (Bonus Points) Provide KNIME workflow?
Citation
If you are interested in citing the repository, I have generated a DOI link using Zenodo here:
For those using a citation manager, there is also a compressed endnote file that is available and can be downloaded here
Thanks for your interest!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file py50-1.0.8.tar.gz
.
File metadata
- Download URL: py50-1.0.8.tar.gz
- Upload date:
- Size: 41.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.0 CPython/3.9.18 Darwin/23.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2f479791b604ea3a0e067df59825c44f46118012b014fb183268655767c6a4f5 |
|
MD5 | 479b3550d5e997868621e3e3b84eea57 |
|
BLAKE2b-256 | 314cee5ece282ee9c901314bc0dc93fdc8215fd68cd1248ed66cc766c8609a8f |
File details
Details for the file py50-1.0.8-py3-none-any.whl
.
File metadata
- Download URL: py50-1.0.8-py3-none-any.whl
- Upload date:
- Size: 42.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.0 CPython/3.9.18 Darwin/23.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e59ea9d05cdd75e5f18020c414a81a3a0fc8d051aacdcdf110ea2023cf483f70 |
|
MD5 | fde8e3321b2b844a86aeb37bf7902400 |
|
BLAKE2b-256 | f967fde38af963261a5efe91159217f89e88efd5c2ccf6e392b56453acbe2c4c |