metadata
dataset_info:
features:
- name: Age
dtype: int64
- name: Gender
dtype: int64
- name: Air_Pollution
dtype: int64
- name: Alcohol_use
dtype: int64
- name: Dust_Allergy
dtype: int64
- name: OccuPational_Hazards
dtype: int64
- name: Genetic_Risk
dtype: int64
- name: chronic_Lung_Disease
dtype: int64
- name: Balanced_Diet
dtype: int64
- name: Obesity
dtype: int64
- name: Smoking
dtype: int64
- name: Passive_Smoker
dtype: int64
- name: Chest_Pain
dtype: int64
- name: Coughing_of_Blood
dtype: int64
- name: Fatigue
dtype: int64
- name: Weight_Loss
dtype: int64
- name: Shortness_of_Breath
dtype: int64
- name: Wheezing
dtype: int64
- name: Swallowing_Difficulty
dtype: int64
- name: Clubbing_of_Finger_Nails
dtype: int64
- name: Frequent_Cold
dtype: int64
- name: Dry_Cough
dtype: int64
- name: Snoring
dtype: int64
- name: Level
dtype:
class_label:
names:
'0': Low
'1': Medium
'2': High
splits:
- name: train
num_bytes: 192000
num_examples: 1000
- name: test
num_bytes: 192000
num_examples: 1000
download_size: 40754
dataset_size: 384000
configs:
- config_name: default
data_files:
- split: train
path: data/train-*
- split: test
path: data/test-*
Lung Cancer Risk Classification Dataset
Purpose
This dataset is designed for building machine learning models to predict the risk level of lung cancer based on patient demographics, lifestyle, and medical history.
It can be used for research, model training, and educational purposes in healthcare AI applications.
The dataset contains 23 input features and one target label (Level) with three classes:
- Low (0)
- Medium (1)
- High (2)
Dataset Guide
Features
| Feature Name | Type | Description |
|---|---|---|
| Age | int | Patient age |
| Gender | int | Gender encoded as 0/1 |
| Air_Pollution | int | Exposure to air pollution |
| Alcohol_use | int | Alcohol consumption indicator |
| Dust_Allergy | int | Presence of dust allergy |
| OccuPational_Hazards | int | Occupational hazards exposure |
| Genetic_Risk | int | Genetic risk factor |
| chronic_Lung_Disease | int | History of chronic lung disease |
| Balanced_Diet | int | Balanced diet indicator |
| Obesity | int | Obesity indicator |
| Smoking | int | Smoking habit indicator |
| Passive_Smoker | int | Exposure to passive smoking |
| Chest_Pain | int | Chest pain indicator |
| Coughing_of_Blood | int | Presence of blood in cough |
| Fatigue | int | Fatigue indicator |
| Weight_Loss | int | Weight loss indicator |
| Shortness_of_Breath | int | Shortness of breath indicator |
| Wheezing | int | Wheezing indicator |
| Swallowing_Difficulty | int | Difficulty swallowing indicator |
| Clubbing_of_Finger_Nails | int | Clubbing of finger nails indicator |
| Frequent_Cold | int | Frequency of colds |
| Dry_Cough | int | Dry cough indicator |
| Snoring | int | Snoring indicator |
| Level | class | Target label: 0=Low, 1=Medium, 2=High |
Recommended Usage
- Load the dataset using the
datasetslibrary:
from datasets import load_dataset
dataset = load_dataset("edcelbogs/lung-cancer-classification")
### Prepare for training in TensorFlow or PyTorch:
#Example Convert to TensorFlow dataset:
tf_dataset = dataset["train"].to_tf_dataset(
columns=[c for c in dataset["train"].column_names if c != "Level"],
label_cols="Level",
shuffle=True,
batch_size=32
)