Skip to content

A web-based tool that uses your webcam to intuitively explore the concept of a regression coefficient (β) in real-time

License

Notifications You must be signed in to change notification settings

dbann/regression_visualizer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Interactive Regression Visualizer

Use your hands to visually explore the concept of a regression coefficient (β) + precision in real-time. A demo of an 'intuition-first' approach to learn statistics. Built with AI (gemini 2.5).

try it!

Interactive Regression Visualizer in action

Features

  • Live Hand Tracking: Uses your hands to control the slope of a regression line.
  • Real-time Coefficient Calculation: See the β value change instantly as you move your hands.
  • Interactive Data: Visualize a scatter plot of data points that adjusts to the line.
  • Variable Scaling: Change the scale of the X and Y axes (0-10, 0-100, etc.) to see how it impacts the coefficient.
  • Precision Control: Adjust a slider to see how the tightness (precision) of the data affects your model.

How to Use

  1. Open the link to the application.
  2. Allow camera access when prompted by your browser.
  3. Clap and show both hands to the camera to begin.
  4. Move your hands to change the slope and use the on-screen controls to explore!

Development

This application was created with the help of Google's Gemini Pro. The core functionality is built with standard HTML, JavaScript, and CSS, using the MediaPipe Hands library for hand tracking. Inspired by [this] (https://x.com/googleaidevs/status/1936193938639012065) X thread 21st June 2025.

Related Projects

Feedback

Feedback, questions, and suggestions are welcome. Please contact david.bann@ucl.ac.uk.

License

This project is open source and available under the MIT License.

About

A web-based tool that uses your webcam to intuitively explore the concept of a regression coefficient (β) in real-time

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages