#Stock Price Prediction App A web application that predicts the closing stock price based on the given opening price, high price, low price, and volume using a Linear Regression model. The app is built using Gradio and deployed on Hugging Face Spaces.
Features Interactive UI: Enter stock data and instantly predict the closing price. Visualization: A clean and simple layout for user input and output. Machine Learning: Powered by Scikit-learn’s LinearRegression model. Free Hosting: Hosted permanently on Hugging Face Spaces. How It Works Input: User provides four stock parameters: Opening Price High Price Low Price Volume Model: The app uses a trained Linear Regression model to predict the closing price. Output: The predicted closing price is displayed as the result. Installation Instructions Follow these steps to run the app locally:
Prerequisites Make sure you have the following installed:
Python 3.7 or higher Required Python packages: gradio, numpy, pandas, scikit-learn, matplotlib Steps Clone the Repository: bash Copy code git clone https://github.com/Pebin-Joseph/Stock-Predict.git cd stock-price-prediction Install Dependencies: bash Copy code pip install -r requirements.txt Run the App:
Copy code python app.py Open your browser and go to http://127.0.0.1:7860 to interact with the app. Project Structure plaintext Copy code 📦 stock-price-prediction ├── app.py # Main application script ├── requirements.txt # List of dependencies ├── GOOG.csv # Dataset used for training └── README.md # Documentation Model Details The model was trained using a Linear Regression algorithm from Scikit-learn. Below are the details:
Dataset The data used for this project is from Google’s stock market history, containing:
open: Opening price of the stock. high: Highest price of the stock. low: Lowest price of the stock. volume: Total number of shares traded. close: Closing price of the stock (target variable). Training The dataset was split into:
80% Training Data 20% Testing Data Key performance metrics:
Mean Absolute Error (MAE): [Insert Value] Root Mean Squared Error (RMSE): [Insert Value] Accuracy: [Insert Value] Live Demo You can access the live version of the app hosted on Hugging Face Spaces: Stock Price Prediction App
Technologies Used Python: Programming language Gradio: For creating the web-based user interface Scikit-learn: For model training and evaluation Pandas: For data manipulation Matplotlib/Seaborn: For data visualization Contributing Contributions are welcome! To contribute:
Fork this repository. Create a feature branch: bash Copy code git checkout -b feature-name Commit your changes: bash Copy code git commit -m "Add feature" Push to the branch: bash Copy code git push origin feature-name Open a pull request. License This project is licensed under the MIT License.
Acknowledgements Hugging Face Spaces for free hosting. Gradio for providing an easy-to-use UI framework. Scikit-learn for the robust machine learning libraries. Feel free to copy and paste this into your GitHub repository. Update placeholders like your-username and metrics values if necessary. Let me know if you'd like further customization!