{ "cells": [ { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [], "source": [ "import pandas as pd\n", "import numpy as np\n", "import matplotlib.pyplot as plt\n" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
PregnanciesGlucoseBloodPressureSkinThicknessInsulinBMIDiabetesPedigreeFunctionAgeOutcome
061487235033.60.627501
11856629026.60.351310
28183640023.30.672321
318966239428.10.167210
40137403516843.12.288331
\n", "
" ], "text/plain": [ " Pregnancies Glucose BloodPressure SkinThickness Insulin BMI \\\n", "0 6 148 72 35 0 33.6 \n", "1 1 85 66 29 0 26.6 \n", "2 8 183 64 0 0 23.3 \n", "3 1 89 66 23 94 28.1 \n", "4 0 137 40 35 168 43.1 \n", "\n", " DiabetesPedigreeFunction Age Outcome \n", "0 0.627 50 1 \n", "1 0.351 31 0 \n", "2 0.672 32 1 \n", "3 0.167 21 0 \n", "4 2.288 33 1 " ] }, "execution_count": 2, "metadata": {}, "output_type": "execute_result" } ], "source": [ "df_diabetes = pd.read_csv('diabetes.csv')\n", "df_diabetes.head()" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
agesexcptrestbpscholfbsrestecgthalachexangoldpeakslopecathaltarget
052101252120116801.02230
153101402031015513.10030
270101451740112512.60030
361101482030116100.02130
462001382941110601.91320
\n", "
" ], "text/plain": [ " age sex cp trestbps chol fbs restecg thalach exang oldpeak slope \\\n", "0 52 1 0 125 212 0 1 168 0 1.0 2 \n", "1 53 1 0 140 203 1 0 155 1 3.1 0 \n", "2 70 1 0 145 174 0 1 125 1 2.6 0 \n", "3 61 1 0 148 203 0 1 161 0 0.0 2 \n", "4 62 0 0 138 294 1 1 106 0 1.9 1 \n", "\n", " ca thal target \n", "0 2 3 0 \n", "1 0 3 0 \n", "2 0 3 0 \n", "3 1 3 0 \n", "4 3 2 0 " ] }, "execution_count": 7, "metadata": {}, "output_type": "execute_result" } ], "source": [ "df_heart = pd.read_csv(\"heart_complete.csv\")\n", "df_heart.head()" ] }, { "cell_type": "code", "execution_count": 8, "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
AgeGenderHeightWeightBMIPhysicalActivityLevelObesityCategory
056Male173.57526271.98205123.8917834Normal weight
169Male164.12730689.95925633.3952092Obese
246Female168.07220272.93062925.8177374Overweight
332Male168.45963384.88691229.9122473Overweight
460Male183.56856869.03894520.4879033Normal weight
\n", "
" ], "text/plain": [ " Age Gender Height Weight BMI PhysicalActivityLevel \\\n", "0 56 Male 173.575262 71.982051 23.891783 4 \n", "1 69 Male 164.127306 89.959256 33.395209 2 \n", "2 46 Female 168.072202 72.930629 25.817737 4 \n", "3 32 Male 168.459633 84.886912 29.912247 3 \n", "4 60 Male 183.568568 69.038945 20.487903 3 \n", "\n", " ObesityCategory \n", "0 Normal weight \n", "1 Obese \n", "2 Overweight \n", "3 Overweight \n", "4 Normal weight " ] }, "execution_count": 8, "metadata": {}, "output_type": "execute_result" } ], "source": [ "df_obesity = pd.read_csv(\"obesity_data.csv\")\n", "df_obesity.head()" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3.9.18 ('ds_ml')", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.9.18" }, "orig_nbformat": 4, "vscode": { "interpreter": { "hash": "bcc4fb5aa31885ae3822c808f45050c24798a2479b24a824a4f952e5682b37fd" } } }, "nbformat": 4, "nbformat_minor": 2 }