Py
Py
Run
What do you want to learn?
Lessons
⌄
Browse the curriculum
Find your level
Practice problems
Interview prep
Cheat sheets
Career paths
Explore by role
All lessons
Fundamentals
Web development
Data
Engineering
Data science
Machine learning
GenAI & RAG
Automation
DSA / interview
Tools
new
⌄
Online compiler
Playground
Revise
Terminal
SQL playground
Notebook
Build
⌄
Workspaces
Guided projects
My published sites
Blog
Pricing
AI
en
Sign in
Start free
→
Start free
→
loading…
Feedback
💬
Ask PyRun
Home
›
All lessons
›
Machine Learning
›
Your First Machine-Learning Model
Your First Machine-Learning Model
Advanced
12 min
Machine Learning
machine-learning · sklearn · regression
Try it
↓
Lesson
1
of
6
In this track
▾
1
Your First Machine-Learning Model
12 min
2
Train/Test Split: Don't Fool Yourself
12 min
3
Regression: Predicting a Number
14 min
4
Classification: Predicting a Category
14 min
5
Decision Trees & Feature Importance
13 min
6
Overfitting & Honest Evaluation
14 min
←
→
Loading lesson…
←
Previous lesson
String matching — naive, hashed, and 'just use in'
Advanced · 11 min
Next lesson
→
Train/Test Split: Don't Fool Yourself
Advanced · 12 min
Related lessons
Advanced · 14 min
Regression: Predicting a Number
Fit, predict, and score a regression model with R² and MAE.
Advanced · 12 min
Train/Test Split: Don't Fool Yourself
Why you must hold data back, and how to measure honest accuracy.
Advanced · 14 min
Classification: Predicting a Category
Predict yes/no outcomes with logistic regression and read accuracy.