-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathShellScript.sh
executable file
·58 lines (42 loc) · 1.04 KB
/
ShellScript.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
# Install Python and configure python
apt install -y python3
apt install -y python3-pip
pip3 install tweepy
pip3 install pandas
# Run The Web Crawler file to generate info.csv
python3 src/crawler/Crawl.py
# Install Java
apt install -y openjdk-11-jre-headless
# Install Maven
apt install -y maven
# Maven Builds
mvn clean
mvn test
mvn install
mvn site
# Move Crawler output Excel file to Sentimental Analysis workspace
mv src/crawler/info.csv src/sentimental_analysis
# Install Machine Learning libraries
pip3 install keras
pip3 install tensorflow
# Move to Machine Learning folder from Crawler folder
cd ..
cd sentimental_analysis
# Switch case to select Machine Learning Model
echo "Sentimental Analysis Use cases"
# Option Menu
echo "1) Random Forest"
echo "2) Decision Tree"
echo "3) Naive Bayes"
read -p "Enter your choice: " ch
# Switch case
case "$ch" in
1) python3 randomforest.py ;;
2) python3 decisiontree.py ;;
3) python3 naivebayes.py ;;
esac
# Visualization
apt-get install -y python3-matplotlib
cd ..
cd visualization
python3 matplotlib.py