Migraine Navigator is a comprehensive tool designed to help users both track and predict migraine occurrences. By combining detailed logging of migraine episodes with advanced machine learning models, this project empowers users to better understand their migraine patterns and anticipate future episodes.
- Migraine Tracking: Log migraine events, symptoms, triggers, medications, and weather data.
- Migraine Prediction: Predict the likelihood of future migraine episodes using state-of-the-art machine learning and ensemble models.
- Data Visualization: Visualize trends and patterns in your migraine history.
- Customizable Analysis: Integrate your own data and adjust model parameters for personalized insights.
Install dependencies with:
pip install -r requirements.txt
Main dependencies:
- pandas
- numpy
- matplotlib
- seaborn
- scikit-learn
- imbalanced-learn
- xgboost
- tensorflow
- meteostat
- geocoder
- pytz
Some models and notebooks require:
- imbalanced-learn (for SMOTE and ensemble methods)
- xgboost (for XGBoost models)
- Run the Application: Execute the
main.py
file to start the application.
python main.py
-
Input Data: Use the "Input" tab to enter migraine instance details. Click the "Save Entry" button to save the data.
-
View Entries: Switch to the "View Entries" tab to see the logged entries in a table.
-
Analyze Data: Go to the "Analysis" tab to perform graphical analysis on the migraine data. Select the type of graph you want to display and click the "Analyze" button.
-
Predict Migraines: Use the "Prediction" tab to predict the likelihood of a migraine based on the input data and current weather conditions. Click the "Predict" button to see the prediction result.
Migraine Navigator/
├── analysis/ # Analysis modules
├── data/ # Data files (CSV, weather, logs)
├── data_import_helpers/ # Scripts for data import/cleaning
├── dummy_logs/ # Example migraine logs
├── input/ # Input frame modules
├── models/ # Saved model files (e.g., .pkl)
├── notebooks/ # Jupyter notebooks for modeling
├── prediction/ # Prediction and ML code
├── screenshots/ # UI screenshots
├── tests/ # Unit tests
├── view/ # View frame modules
├── weather/ # Weather data modules
├── main.py # Main application entry point
├── requirements.txt # Python dependencies
├── README.md # Project documentation
Cannot be shown for reasons of data privacy.
To run the tests, use the following commad:
python -m unittest discover tests
To run a specific test file, use the following command:
python -m unittest tests.test_input
Modify tests.test_{x} for each file in tests/
This project is licensed under the MIT License - see the LICENSE file for details.
- Tkinter for the GUI framework.
- Pandas for data manipulation.
- Matplotlib for plotting graphs.
- Geocoder for location services.
- Pytz for timezone handling.
- Meteostat for weather data.
- Scikit-learn for machine learning algorithms.
- Joblib for model serialization.
- Imbalanced-learn for resampling and ensemble methods.
- XGBoost for gradient boosting models.
- TensorFlow for deep learning models.
- Seaborn for statistical data visualization.
This project was created by Aresh Tajvar.
- GitHub: github.com/AreTaj
- LinkedIn: linkedin.com/in/aresh-tajvar
Feel free to reach out if you have any questions or suggestions!