Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -83,7 +83,7 @@ def analyze_reviews(file_path):
|
|
| 83 |
[df['Sentiment'], df['Sentiment Score']] = zip(*results)
|
| 84 |
|
| 85 |
# Adjust the sentiment score to be negative if the sentiment is negative
|
| 86 |
-
df.loc[df['Sentiment'] == '
|
| 87 |
|
| 88 |
pie_chart, scatter_plot = create_charts(df)
|
| 89 |
|
|
|
|
| 83 |
[df['Sentiment'], df['Sentiment Score']] = zip(*results)
|
| 84 |
|
| 85 |
# Adjust the sentiment score to be negative if the sentiment is negative
|
| 86 |
+
df.loc[df['Sentiment'].lower() == 'negative' , 'Sentiment Score'] *= -1
|
| 87 |
|
| 88 |
pie_chart, scatter_plot = create_charts(df)
|
| 89 |
|