Skip to content

Commit

Permalink
yui
Browse files Browse the repository at this point in the history
  • Loading branch information
SB2520 committed Jun 19, 2024
1 parent 6ca3f60 commit 0fded05
Show file tree
Hide file tree
Showing 6 changed files with 1,296 additions and 123 deletions.
13 changes: 10 additions & 3 deletions backend-python/Sentiment Analysis/bitcoin/app.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,20 @@
from flask import Flask, render_template
import pandas as pd

app = Flask(__name__)

# Function to read probabilities from CSV file
def read_probabilities_from_csv(file_path):
df = pd.read_csv(file_path)
probability_increase = df.iloc[0]['Probability of Increase']
probability_decrease = df.iloc[0]['Probability of Decrease']
return probability_decrease, probability_increase

# Define route to display probabilities
@app.route('/')
def index():
# Define probabilities (you can fetch these from a database or other source)
probability_decrease = 0.73
probability_increase = 0.27
# Read probabilities from CSV file
probability_decrease, probability_increase = read_probabilities_from_csv('probabilities.csv')

# Render HTML template with probabilities passed as variables
return render_template('index.html', prob_decrease=probability_decrease, prob_increase=probability_increase)
Expand Down
2 changes: 1 addition & 1 deletion backend-python/Sentiment Analysis/bitcoin/btc.csv
Original file line number Diff line number Diff line change
Expand Up @@ -3562,4 +3562,4 @@ Date,Open,High,Low,Close,Volume,Dividends,Stock Splits
2024-06-16 00:00:00+00:00,66189.359375,66894.84375,66018.25,66639.046875,13281140541,0.0,0.0
2024-06-17 00:00:00+00:00,66636.515625,67188.3203125,65094.96484375,66490.296875,30006354476,0.0,0.0
2024-06-18 00:00:00+00:00,66490.9765625,66556.703125,64066.95703125,65140.74609375,39481285950,0.0,0.0
2024-06-19 00:00:00+00:00,65146.66015625,65617.1015625,64834.99609375,65083.0390625,34417197056,0.0,0.0
2024-06-19 00:00:00+00:00,65146.66015625,65617.1015625,64834.99609375,65019.7890625,33921107968,0.0,0.0
4 changes: 2 additions & 2 deletions backend-python/Sentiment Analysis/bitcoin/btcSentiment.csv
Original file line number Diff line number Diff line change
Expand Up @@ -3561,5 +3561,5 @@
2024-06-15 00:00:00+00:00,66006.7421875,66402.1875,65871.7734375,66191.0,14121265576,0.5333333333333333,-0.0554533522438119,0.1101851851851852,66639.046875,1
2024-06-16 00:00:00+00:00,66189.359375,66894.84375,66018.25,66639.046875,13281140541,0.5333333333333333,-0.0554533522438119,0.1101851851851852,66490.296875,0
2024-06-17 00:00:00+00:00,66636.515625,67188.3203125,65094.96484375,66490.296875,30006354476,0.5666666666666667,-0.0240517299484323,0.1101851851851852,65140.74609375,0
2024-06-18 00:00:00+00:00,66490.9765625,66556.703125,64066.95703125,65140.74609375,39481285950,0.5666666666666667,-0.0240517299484323,0.1101851851851852,65083.0390625,0
2024-06-19 00:00:00+00:00,65146.66015625,65617.1015625,64834.99609375,65083.0390625,34417197056,0.5666666666666667,-0.0240517299484323,0.1101851851851852,,0
2024-06-18 00:00:00+00:00,66490.9765625,66556.703125,64066.95703125,65140.74609375,39481285950,0.5666666666666667,-0.0240517299484323,0.1101851851851852,65019.7890625,0
2024-06-19 00:00:00+00:00,65146.66015625,65617.1015625,64834.99609375,65019.7890625,33921107968,0.5666666666666667,-0.0240517299484323,0.1101851851851852,,0
281 changes: 182 additions & 99 deletions backend-python/Sentiment Analysis/bitcoin/prediction_btc.ipynb

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Probability of Increase,Probability of Decrease
0.4669906844876468,0.5330093155123532
1,117 changes: 1,099 additions & 18 deletions backend-python/Sentiment Analysis/tether/tether.ipynb

Large diffs are not rendered by default.

0 comments on commit 0fded05

Please sign in to comment.