Dataset Viewer
Auto-converted to Parquet Duplicate
Patient_ID
string
Cancer_Type
string
Age
int64
Gender
int64
Smoking
int64
Alcohol_Use
int64
Obesity
int64
Family_History
int64
Diet_Red_Meat
int64
Diet_Salted_Processed
int64
Fruit_Veg_Intake
int64
Physical_Activity
int64
Air_Pollution
int64
Occupational_Hazards
int64
BRCA_Mutation
int64
H_Pylori_Infection
int64
Calcium_Intake
int64
Overall_Risk_Score
float64
BMI
float64
Physical_Activity_Level
int64
Risk_Level
string
LU0000
Breast
68
0
7
2
8
0
5
3
7
4
6
3
1
0
0
0.398696
28
5
Medium
LU0001
Prostate
74
1
8
9
8
0
0
3
7
1
3
3
0
0
5
0.424299
25.4
9
Medium
LU0002
Skin
55
1
7
10
7
0
3
3
4
1
8
10
0
0
6
0.605082
28.6
2
Medium
LU0003
Colon
61
0
6
2
2
0
6
2
4
6
4
8
0
0
8
0.318449
32.1
7
Low
LU0004
Lung
67
1
10
7
4
0
6
3
10
9
10
9
0
0
5
0.524358
25.1
2
Medium
LU0005
Lung
77
1
10
8
3
0
6
0
6
2
10
7
0
0
0
0.498668
25.1
1
Medium
LU0006
Lung
59
0
10
10
0
0
9
4
0
1
10
9
0
0
5
0.662354
32.3
2
High
LU0007
Prostate
74
1
8
6
2
1
3
3
2
8
8
7
0
0
1
0.479367
29.1
9
Medium
LU0008
Colon
71
1
9
0
3
0
10
4
6
10
8
3
0
0
5
0.49762
24.1
5
Medium
LU0009
Skin
55
1
7
1
2
0
0
4
2
5
9
9
0
0
5
0.404837
28.2
1
Medium
LU0010
Lung
63
0
10
4
3
1
0
10
10
8
8
4
0
0
4
0.494523
24.1
7
Medium
LU0011
Prostate
82
1
8
0
5
0
1
1
1
5
5
10
0
0
4
0.344799
24.1
0
Medium
LU0012
Skin
55
0
9
9
8
0
4
6
3
2
2
10
0
0
4
0.64423
27
6
Medium
LU0013
Lung
68
0
10
9
1
0
0
2
7
4
4
6
0
0
5
0.354041
18.3
1
Medium
LU0014
Lung
66
1
10
8
2
0
5
0
5
8
5
3
0
0
1
0.35698
19.1
9
Medium
LU0015
Lung
69
1
10
7
6
0
1
2
9
3
8
4
0
0
2
0.503353
23.8
5
Medium
LU0016
Breast
67
0
7
7
7
0
2
8
10
1
7
9
0
0
2
0.520842
21.9
1
Medium
LU0017
Colon
60
1
10
8
0
0
5
4
1
0
5
5
0
0
4
0.58324
27.3
1
Medium
LU0018
Breast
66
0
10
6
8
0
1
4
1
5
8
10
0
0
4
0.5915
22.4
9
Medium
LU0019
Breast
58
0
2
10
7
0
10
3
4
2
7
2
0
0
0
0.529895
20.4
7
Medium
LU0020
Colon
75
1
9
0
5
0
10
6
2
9
7
7
0
0
0
0.509579
31.9
1
Medium
LU0021
Lung
71
1
10
7
9
1
1
1
3
8
10
6
0
0
4
0.546737
25.1
6
Medium
LU0022
Breast
64
0
7
7
10
1
0
0
1
2
9
0
0
0
2
0.403662
26.3
2
Medium
LU0023
Breast
70
0
10
10
10
0
6
0
2
3
5
7
0
0
0
0.572908
20.3
7
Medium
LU0024
Breast
75
0
9
8
8
0
2
8
7
10
7
9
1
0
4
0.669148
23.8
6
High
LU0025
Skin
64
1
9
6
3
1
5
4
2
2
9
7
0
0
8
0.527521
26.4
7
Medium
LU0026
Lung
68
1
10
3
5
1
0
1
1
5
4
8
0
1
0
0.450875
21.4
6
Medium
LU0027
Colon
65
0
9
5
3
0
9
4
0
10
8
1
0
0
4
0.620659
27.5
10
Medium
LU0028
Colon
67
1
5
0
0
0
9
5
5
5
6
5
0
0
2
0.360223
23.6
5
Medium
LU0029
Lung
54
1
10
4
3
0
5
0
2
4
10
3
0
1
8
0.445116
24.8
6
Medium
LU0030
Colon
69
1
10
7
2
1
8
3
8
8
7
1
0
0
1
0.506474
23.6
4
Medium
LU0031
Lung
71
0
10
0
8
0
2
0
9
10
10
9
0
0
3
0.578075
33.4
6
Medium
LU0032
Lung
64
1
10
4
5
0
4
1
8
5
9
0
0
0
2
0.408368
25.9
0
Medium
LU0033
Prostate
76
1
8
7
4
0
2
0
4
5
1
8
0
0
3
0.333549
21.8
0
Medium
LU0034
Prostate
90
1
10
3
8
0
3
2
2
10
6
9
0
0
0
0.449183
29.3
7
Medium
LU0035
Skin
57
0
9
3
10
0
3
0
10
0
7
8
0
0
6
0.497101
21.1
4
Medium
LU0036
Breast
65
0
6
7
10
0
3
2
7
7
7
2
0
0
2
0.440081
26.8
4
Medium
LU0037
Lung
73
0
10
7
4
0
6
3
6
4
10
2
0
0
4
0.6255
18.2
2
Medium
LU0038
Colon
85
0
7
9
5
0
5
4
0
6
8
10
0
0
2
0.688493
20.7
4
High
LU0039
Breast
56
0
6
8
10
0
5
2
9
9
6
0
0
1
0
0.410781
26.8
2
Medium
LU0040
Lung
75
1
10
1
3
0
5
4
3
8
5
2
0
0
2
0.339462
29
8
Medium
LU0041
Breast
72
0
7
6
6
0
4
4
1
6
10
4
0
0
0
0.516189
26.7
8
Medium
LU0042
Lung
61
0
10
6
1
0
3
1
2
4
10
2
0
0
2
0.482361
25.5
5
Medium
LU0043
Prostate
70
1
10
7
3
1
6
4
0
9
5
4
0
0
2
0.502851
24.8
0
Medium
LU0044
Breast
62
0
6
6
9
0
4
4
6
8
6
1
0
0
4
0.417638
20.1
6
Medium
LU0045
Colon
59
1
10
8
7
0
10
4
0
10
7
4
0
0
3
0.622056
23.1
6
Medium
LU0046
Breast
75
0
10
10
10
1
8
9
2
3
0
4
0
0
0
0.618576
24.2
9
Medium
LU0047
Colon
67
1
9
6
5
0
10
2
2
5
0
9
0
0
3
0.542624
30.2
9
Medium
LU0048
Colon
72
1
10
9
3
0
7
3
0
0
10
6
0
0
2
0.564548
27.4
3
Medium
LU0049
Lung
63
0
10
2
4
0
5
7
8
4
9
7
0
0
2
0.524478
18.9
7
Medium
LU0050
Prostate
68
1
7
10
4
0
7
4
8
1
9
5
0
0
2
0.633097
27.3
4
Medium
LU0051
Skin
58
1
8
4
8
0
2
5
1
2
8
10
0
1
5
0.524082
24.5
3
Medium
LU0052
Prostate
81
1
10
8
7
0
9
4
3
3
2
3
0
0
1
0.465194
23.3
2
Medium
LU0053
Prostate
60
1
10
8
4
0
0
2
1
1
5
0
0
0
3
0.36725
28.4
0
Medium
LU0054
Colon
68
0
2
9
4
0
7
9
0
1
6
0
0
0
8
0.444476
30.1
1
Medium
LU0055
Prostate
80
1
6
2
9
1
3
3
9
5
0
9
0
0
5
0.438071
29.7
2
Medium
LU0056
Lung
52
1
10
4
1
0
2
0
6
2
4
5
0
0
3
0.340874
22.6
4
Medium
LU0057
Lung
69
0
10
7
6
0
3
1
7
6
10
0
0
0
6
0.460904
24.8
7
Medium
LU0058
Lung
79
1
10
8
2
0
1
2
3
7
10
4
0
0
5
0.459448
27.3
5
Medium
LU0059
Breast
67
0
10
8
9
0
0
3
2
0
5
7
0
0
0
0.488207
29.9
3
Medium
LU0060
Breast
65
0
6
10
7
0
7
6
9
1
5
3
0
0
2
0.554167
24.1
10
Medium
LU0061
Breast
77
0
10
9
9
0
1
0
0
2
5
9
0
0
0
0.581564
25.3
6
Medium
LU0062
Skin
49
0
6
9
9
0
3
2
10
5
10
9
0
0
1
0.551328
21.6
7
Medium
LU0063
Breast
59
0
7
2
8
1
2
1
1
7
0
6
0
0
0
0.33723
21.2
1
Medium
LU0064
Breast
56
0
1
1
8
0
7
1
5
5
5
0
0
0
2
0.339419
29.3
6
Medium
LU0065
Colon
65
0
7
7
6
0
10
6
0
9
8
7
0
0
2
0.662771
31.4
1
High
LU0066
Lung
53
1
10
10
4
0
0
1
7
5
10
7
0
1
3
0.590474
25.7
1
Medium
LU0067
Skin
57
0
9
8
7
0
4
4
6
7
6
6
0
0
3
0.521593
30
7
Medium
LU0068
Lung
69
1
10
7
4
0
2
3
4
0
10
9
0
0
4
0.470962
27.4
1
Medium
LU0069
Prostate
77
1
10
6
7
1
1
5
4
2
6
8
0
0
0
0.560033
23.4
9
Medium
LU0070
Skin
70
0
4
9
2
0
4
0
8
6
10
4
0
0
2
0.430629
27.4
8
Medium
LU0071
Lung
68
1
10
4
8
0
5
3
9
4
8
1
0
0
5
0.555921
32.2
0
Medium
LU0072
Lung
70
1
10
4
0
1
5
3
3
7
10
2
0
0
9
0.496907
25.9
8
Medium
LU0073
Skin
80
0
9
7
6
0
3
3
1
0
4
4
0
0
3
0.476837
32.3
0
Medium
LU0074
Skin
67
1
9
7
10
0
8
3
10
2
8
10
0
0
5
0.72577
15.5
9
High
LU0075
Skin
76
0
6
10
2
0
4
4
0
4
10
9
0
0
10
0.552909
29.3
9
Medium
LU0076
Skin
65
0
10
7
5
0
0
0
0
10
5
10
0
0
3
0.401544
26.3
1
Medium
LU0077
Lung
63
0
10
3
4
0
5
9
4
1
8
4
0
0
0
0.543386
24.8
5
Medium
LU0078
Breast
72
0
10
9
4
0
3
4
9
8
7
3
1
0
3
0.549129
26.4
5
Medium
LU0079
Lung
61
1
10
7
4
0
9
3
7
0
10
4
0
0
4
0.620318
18
0
Medium
LU0080
Prostate
82
1
0
10
5
0
8
3
1
1
3
6
0
0
3
0.47919
25.1
5
Medium
LU0081
Colon
74
1
6
7
3
0
10
5
0
1
5
5
0
0
9
0.491112
27.4
7
Medium
LU0082
Breast
63
0
8
6
5
0
5
10
9
2
8
1
0
0
0
0.524223
31.9
1
Medium
LU0083
Lung
62
0
10
8
6
0
2
3
10
1
9
8
0
1
1
0.599171
23.9
7
Medium
LU0084
Breast
54
0
8
0
4
0
1
8
6
5
7
8
0
0
0
0.422675
22.8
8
Medium
LU0085
Breast
73
0
7
10
8
1
3
3
9
7
1
3
0
0
0
0.424214
24
5
Medium
LU0086
Skin
71
1
5
9
10
0
4
0
7
0
9
10
0
0
3
0.602399
29.7
4
Medium
LU0087
Colon
60
1
9
6
10
1
6
4
3
10
9
8
1
0
10
0.700545
27.3
8
High
LU0088
Prostate
64
1
9
3
1
0
3
3
0
5
10
1
0
0
3
0.365024
23.9
9
Medium
LU0089
Breast
45
0
7
9
7
1
1
4
6
10
6
8
0
0
4
0.479341
28.1
8
Medium
LU0090
Lung
68
1
10
2
10
0
0
8
0
4
10
5
0
0
1
0.52571
26.4
0
Medium
LU0091
Skin
69
0
6
7
4
1
0
1
8
10
10
10
0
0
4
0.497684
29.9
10
Medium
LU0092
Skin
61
1
10
9
8
0
3
1
5
3
10
10
0
0
4
0.647076
23.2
2
Medium
LU0093
Colon
57
1
7
3
9
0
5
3
1
6
7
2
0
0
0
0.462062
24.7
8
Medium
LU0094
Skin
64
1
10
8
9
0
0
4
10
3
9
6
0
1
3
0.601065
24.4
10
Medium
LU0095
Breast
62
0
4
9
10
0
3
2
9
9
10
9
0
0
0
0.587791
20.1
1
Medium
LU0096
Colon
63
0
7
6
5
0
10
5
5
3
10
9
0
1
2
0.663253
27.2
3
High
LU0097
Breast
62
0
10
4
7
0
6
4
8
7
2
5
0
0
0
0.472749
27
3
Medium
LU0098
Lung
75
1
10
6
2
0
3
0
0
3
8
0
0
1
0
0.419937
26
1
Medium
LU0099
Lung
61
1
6
5
8
0
6
0
10
10
10
7
0
0
4
0.596617
25.1
2
Medium
End of preview. Expand in Data Studio

🧬 Cancer Risk Factors & Types (2,000 Rows)

Author: Tarek Masryo Β· Kaggle
License: CC BY 4.0 (Attribution) β€” Free for research, education, and commercial use


πŸ“Œ Dataset Summary

Clean, standardized tabular dataset linking lifestyle, environmental, and genetic factors to five cancer types.

  • 2,000 rows Γ— 21 columns
  • Encodings: ordinal exposure indices (0–10), demographics (Age, BMI, Gender), binary flags (0/1) for family/genetics/infection
  • Includes engineered fields: Overall_Risk_Score ∈ [0,1] and Risk_Level ∈ {Low, Medium, High}

Ideal for:

  • EDA and interactive dashboards
  • Multiclass tabular ML (Cancer_Type)
  • Class-imbalance handling and reporting beyond accuracy (e.g., macro-F1)
  • Teaching feature engineering and ordinal/binary encodings

πŸ—‚ Dataset Structure

Main file: data/cancer-risk-factors.csv (one row per individual)

Targets & Tasks

  • Primary target: Cancer_Type ∈ {Lung, Breast, Colon, Prostate, Skin} β€” multiclass classification
  • Optional task: Risk_Level derived from Overall_Risk_Score
    • Default thresholds: Low < 0.35, 0.35 ≀ Medium ≀ 0.65, High > 0.65

Data splits

  • Single CSV; when loaded via πŸ€— Datasets, it appears as a train split by default.

πŸ“‘ Data Dictionary

Column Description
Patient_ID Unique individual identifier
Age Age in years
Gender 0 = Female, 1 = Male
BMI Body Mass Index
Smoking Ordinal exposure index (0–10)
Alcohol_Use Ordinal exposure index (0–10)
Obesity Ordinal index (0–10) of obesity-related risk behaviors
Diet_Red_Meat Ordinal intake frequency (0–10)
Diet_Salted_Processed Ordinal intake frequency (0–10)
Fruit_Veg_Intake Ordinal servings/frequency (0–10)
Physical_Activity Ordinal behavior/frequency (0–10)
Physical_Activity_Level Self-rated activity level (0–10)
Air_Pollution Ordinal exposure index (0–10)
Occupational_Hazards Ordinal exposure index (0–10)
Calcium_Intake Ordinal intake frequency (0–10)
Family_History 0/1 β€” positive family history
BRCA_Mutation 0/1 β€” BRCA mutation flag
H_Pylori_Infection 0/1 β€” Helicobacter pylori infection
Overall_Risk_Score Composite risk score in [0,1] (higher with higher exposures)
Risk_Level Low / Medium / High (thresholds above)
Cancer_Type Lung / Breast / Colon / Prostate / Skin

0–10 indices represent ordinal intensity/frequency (0 = none/very low … 10 = very high).


πŸš€ Usage

Load with πŸ€— Datasets (recommended)

from datasets import load_dataset

ds = load_dataset("tarekmasryo/cancer-risk-factors-data")
df = ds["train"].to_pandas()

print(df.shape)
print(df.head())

Load with pandas (works anywhere)

import pandas as pd
from huggingface_hub import hf_hub_download

path = hf_hub_download(
    repo_id="tarekmasryo/cancer-risk-factors-data",
    repo_type="dataset",
    filename="data/cancer-risk-factors.csv",
)

df = pd.read_csv(path)
print(df.shape)

πŸ§ͺ Quick Modeling Tips

  • Use stratified splits/CV for Cancer_Type (multiclass) and for Risk_Level (imbalanced).
  • Report macro-F1 alongside accuracy; add a per-class confusion matrix.
  • For tree-based models, 0–10 can remain integers; for linear models, consider scaling.
  • Consider class weights or focal loss-style approaches if you see strong imbalance.

🧭 Ethical Considerations

Educational/research dataset only β€” not for clinical use, diagnosis, or treatment.


πŸ“š Citation

Tarek Masryo. (2025). Cancer Risk Factors & Types (2,000 Rows). Hugging Face Datasets.

πŸ“œ License

CC BY 4.0 (Attribution) β€” Free to share and adapt with attribution.

Downloads last month
45