Stock Market Prediction Web App based on Machine Learning and Sentiment Analysis of Tweets (API keys included in code). The front end of the Web App is based on Flask and Wordpress. The App forecasts stock prices of the next seven days for any given stock under NASDAQ or NSE as input by the user. Predictions are made using three algorithms: ARIMA, LSTM, Linear Regression. The Web App combines the predicted prices of the next seven days with the sentiment analysis of tweets to give recommendation whether the price is going to rise or fall
股市预测机器学习网页应用
基于机器学习和推文情绪分析的股市预测Web应用程序,代码中已包含API密钥。前端基于Flask和WordPress。用户输入纳斯达克或NSE上市公司的股票,该应用可预测未来七天的股价。预测使用了三种算法:ARIMA、LSTM、线性回归。通过结合未来七天的预测价格与推文情感分析,给出价格上升或下降的建议。
注意事项
由于GitHub LFS配额超出,已将WordPress文件从存储库移除。请从此链接下载。
截图
更多截图请查看screenshots文件夹 或者 点击此处
文件及目录结构
screenshots - 网页应用的截图
static - Flask应用的静态文件:css、图片、js等
templates - HTML文件
Tweets.py - 情感分析用的推文结构
constants.py - 包含Twitter API密钥和其他配置的应用配置文件
main.py - 主要的机器学习模块
使用的技术
- WordPress
- Flask
- TensorFlow
- Keras
- Yahoo Finance
- Alpha Vantage
- Scikit-Learn
- Tweepy
- Python
- PHP
- CSS
- HTML
- JavaScript
如何安装及使用
需要Python 3.8.5来正确安装Python包
- 克隆仓库。下载并安装XAMPP服务器(https://www.apachefriends.org/download.html),然后启动Apache和MySQL服务器。
- 访问http://localhost/phpmyadmin/ 打开phpmyadmin,在“用户账户”下添加一个用户名为admin的用户,并勾选全局权限,然后点击“Go”。
- 接下来,创建一个新的数据库,命名为wordpress。
- 选择wordpress数据库,点击“导入”,从仓库中选择wordpress.sql文件导入。
- 从[此链接](https://drive.google.com/file/d/1q1kdNBQyQTIIq9OuMuYBUgD3fni-oJQp/view?usp=sharing)下载我的WordPress网站zip文件。
- 将上述zip文件解压到xampp/htdocs文件夹中。
- 打开命令提示符,切换至仓库目录,运行pip install -r requirements.txt安装依赖。
- 在命令提示符中运行python main.py以启动应用。
- 在浏览器中访问http://localhost/www,点击WordPress文件夹访问Web应用。
- WordPress管理面板位于:http://localhost/www/wordpress-5.6.2/wordpress/wp-admin。
设置和演示的视频在这里:[链接](https://drive.google.com/file/d/1iP5RqdlREx_YbP-5RZqo7fB1rElQ2igi/view?usp=sharing)
管理员凭证
用户名: admin
邮箱: stockmarketpred@gmail.com
密码: Samplepass@123
作者
Kaushik Jadhav
- Github:https://github.com/kaushikjadhav01
- Medium:https://medium.com/@kaushikjadhav01
- LinkedIn:https://www.linkedin.com/in/kaushikjadhav01/
- Portfolio:http://kaushikjadhav01.github.io/
Introduction
基于机器学习和推文情绪分析的股市预测网络应用(代码中包含API密钥)。该网络应用的前端基于Flask和Wordpress。应用可为用户输入的任何纳斯达克或印度国家证券交易所的股票预测未来七天的股价。预测采用三种算法:ARIMA、LSTM、线性回归。该网络应用将未来七天的预测股价与推文情绪分析相结合,以提供股价涨跌的建议。【此简介由AI生成】