{"id":23232477,"url":"https://github.com/uznetdev/smoking-prediction","last_synced_at":"2026-04-17T09:31:44.744Z","repository":{"id":259726464,"uuid":"879291551","full_name":"UznetDev/Smoking-Prediction","owner":"UznetDev","description":"This project focuses on analyzing the \"Smoking\" dataset and building a predictive model for smoking status based on various health metrics. The goal is to identify factors influencing smoking behavior and develop a reliable model for prediction.","archived":false,"fork":false,"pushed_at":"2024-11-10T06:54:08.000Z","size":29791,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-05T19:41:53.239Z","etag":null,"topics":["ai","classification","data","data-science","kaggle-competition","machine-learning","ml","roc-auc","sklearn","smoking"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","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/UznetDev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-10-27T14:23:56.000Z","updated_at":"2024-11-24T15:17:52.000Z","dependencies_parsed_at":"2024-10-27T16:32:40.346Z","dependency_job_id":"1a09bdd8-60e6-436b-90c9-b7a8543900ab","html_url":"https://github.com/UznetDev/Smoking-Prediction","commit_stats":null,"previous_names":["uznetdev/nt-m5-h1-smoking-competition-","uznetdev/smoking-prediction","uznetdev/nt-m5-h1-smoking-cmpetition"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UznetDev%2FSmoking-Prediction","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UznetDev%2FSmoking-Prediction/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UznetDev%2FSmoking-Prediction/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UznetDev%2FSmoking-Prediction/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/UznetDev","download_url":"https://codeload.github.com/UznetDev/Smoking-Prediction/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247393539,"owners_count":20931809,"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":["ai","classification","data","data-science","kaggle-competition","machine-learning","ml","roc-auc","sklearn","smoking"],"created_at":"2024-12-19T02:24:16.366Z","updated_at":"2025-10-25T18:42:32.303Z","avatar_url":"https://github.com/UznetDev.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NT-M5-H1 Smoking Prediction Competition\n\nThis repository contains a solution to the **NT-M5-H1 Smoking Prediction Competition**, which focuses on predicting smoking status using health-related data. This project employs machine learning models, primarily using Python and various data science libraries, to create accurate predictions based on provided datasets.\n\n## Project Overview\n\nThe goal of this project is to predict whether an individual is a smoker based on several health indicators. The dataset includes various attributes related to age, height, weight, cholesterol levels, blood pressure, and other health metrics.\n\n### Key Features\n- **Data Analysis and Visualization**: Initial data exploration and visualizations to understand feature distributions and relationships.\n- **Feature Engineering**: Creation of new, relevant features to enhance model performance.\n- **Modeling**: Implementation of multiple classifiers, including logistic regression, decision trees, ensemble methods, and more.\n- **Hyperparameter Tuning**: Finding optimal model parameters using techniques like cross-validation and grid search.\n- **Evaluation**: Assessing model performance using metrics such as ROC-AUC and accuracy.\n\n## Repository Structure\n\n```\nNT-M5-H1-Smoking-Cmpetition/\n├── notebooks/               # Jupyter notebooks for data analysis and modeling\n├── data/                    # datasets for usage model\n├── requirements.txt         # List of required libraries and dependencies\n├── smoking_model.joblib     # Finla model for prediction\n└── README.md                # Project documentation\n```\n  \n## Installation\n\nTo run this project locally, follow these steps:\n\n1. Clone this repository:\n   ```bash\n   git clone https://github.com/UznetDev/NT-M5-H1-Smoking-Cmpetition.git\n   ```\n2. Navigate to the project directory:\n   ```bash\n   cd NT-M5-H1-Smoking-Cmpetition\n   ```\n3. Install the required dependencies:\n   ```bash\n   pip install -r requirements.txt\n   ```\n\n### Usage\n\nTo load and use the model for prediction, follow these steps:\n\n```python\nfrom joblib import load\n\n# Load the model\nmodel = load('smoking_model.joblib')\n\n# Define input data (X) for prediction\n# Example input data for one individual\nX_new = []  # Replace with actual input values\n\n# Predict smoking status\nprediction = model.predict(X_new)\n\n# Display the result\nif prediction[0] == 1:\n    print(\"This individual is likely a smoker.\")\nelse:\n    print(\"This individual is likely a non-smoker.\")\n```\n\n### Model Details\n\nThe `smoking_model.joblib` file contains a pre-trained model created with `scikit-learn`. You can use the `predict` function to determine smoking status based on input health measurements.\n\n**Note:** The example input (`X_new`) should be replaced with real data according to your project requirements.\n\n## Dataset\n\nThe dataset consists of several features related to individuals' health, including:\n- **Basic Attributes**: Age, height, weight, waist circumference, eyesight, and hearing levels.\n- **Blood Pressure**: Systolic and diastolic blood pressure.\n- **Blood Metrics**: Cholesterol, triglyceride, HDL, LDL, and hemoglobin levels.\n- **Additional Health Indicators**: Serum creatinine, AST, ALT, Gtp, and urine protein.\n- **Target**: A binary column indicating whether an individual is a smoker (1 for smoker, 0 for non-smoker).\n\n### Feature Engineering\n\nThe following new features have been engineered to enhance the model's predictive power:\n- **BMI** (Body Mass Index)\n- **Waist-to-Height Ratio**\n- **Cholesterol Ratio** (Total Cholesterol/HDL)\n- **Liver Enzyme Ratio** (ALT/AST)\n\n## Models Used\n\nThe project explores multiple machine learning algorithms for classification:\n- **Linear Models**: Logistic Regression, Ridge Classifier, SGD Classifier\n- **Naive Bayes Classifiers**: GaussianNB, MultinomialNB, BernoulliNB\n- **Support Vector Machines**: SVC, LinearSVC, NuSVC\n- **Decision Trees and Ensembles**: Decision Tree, RandomForest, Gradient Boosting, AdaBoost, Extra Trees\n- **Discriminant Analysis**: Linear Discriminant Analysis, Quadratic Discriminant Analysis\n\n### Hyperparameter Tuning\n\nTo find the best parameters for the models, this project utilizes optuna and cross-validation methods, specifically focusing on maximizing ROC-AUC scores to improve model performance.\n\n## Evaluation\n\nThe models are evaluated based on the following metrics:\n- **ROC-AUC Score**: Primary metric to assess model performance in terms of distinguishing between smokers and non-smokers.\n\n## Usage\n\n1. **Exploratory Data Analysis (EDA)**: Start with EDA notebooks in the `notebooks/` folder to understand the dataset and visualize patterns.\n2. **Model Training**: Run the scripts or notebooks to train the models and evaluate their performance.\n3. **Hyperparameter Tuning**: Use the scripts for hyperparameter tuning to improve model accuracy.\n4. **Save nodel**: save model in 'model.joblib.\n\n\n\n## Contributing\n\nContributions are welcome! If you'd like to improve this project, please fork the repository and make a pull request.\n\n1. Fork the repository.\n2. Create a new branch for your feature or bug fix:\n   ```bash\n   git checkout -b feature-name\n   ```\n3. Commit your changes:\n   ```bash\n   git commit -m \"Add a new feature\"\n   ```\n4. Push to your branch:\n   ```bash\n   git push origin feature-name\n   ```\n5. Open a pull request.\n\n## License\n\nThis project is licensed under the [MIT](LICENCE) License.\n\n## Contact's\n\nIf you have any questions or suggestions, please contact:\n- Email: uznetdev@gmail.com\n- GitHub Issues: [Issues section](https://github.com/UznetDev/NT-M5-H1-Smoking-Cmpetition/issues)\n- GitHub Profile: [UznetDev](https://github.com/UznetDev/)\n- Telegram: [UZNet_Dev](https://t.me/UZNet_Dev)\n- Linkedin: [Abdurakhmon Niyozaliev](https://www.linkedin.com/in/abdurakhmon-niyozaliyev-%F0%9F%87%B5%F0%9F%87%B8-66545222a/)\n\n---\n\nThank you for your interest in this project. We hope it helps in your journey to understand and predict smoking habits using data science!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuznetdev%2Fsmoking-prediction","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fuznetdev%2Fsmoking-prediction","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuznetdev%2Fsmoking-prediction/lists"}