Skip to content

Instantly share code, notes, and snippets.

@shashankvemuri
Last active May 25, 2020 03:17
Show Gist options
  • Save shashankvemuri/4ca980263d147369a8b849b649c8a151 to your computer and use it in GitHub Desktop.
Save shashankvemuri/4ca980263d147369a8b849b649c8a151 to your computer and use it in GitHub Desktop.
imports and parameters needed for code
# Import libraries
import pandas as pd
from bs4 import BeautifulSoup
import matplotlib.pyplot as plt
from urllib.request import urlopen
from urllib.request import Request
from nltk.sentiment.vader import SentimentIntensityAnalyzer
# Parameters
n = 3 #the # of article headlines displayed per ticker
tickers = ['AAPL', 'TSLA', 'AMZN']
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment