app.py is a Streamlit web application that detects whether a credit card transaction is legitimate or fraudulent.
It performs the following key functions:
- Data Preprocessing: Loads transaction data from
creditcard.csvand balances the dataset by undersampling the majority class (legitimate transactions). - Model Training: Trains a Logistic Regression model on the balanced dataset.
- Web Interface: Provides a Streamlit UI allowing users to input a comma-separated list of transaction features to receive a real-time prediction.
You can start the web application by running:
streamlit run app.py