$ pip install pygooglenews --upgrade
from pygooglenews import GoogleNews gn = GoogleNews()
top = gn.top_news()
business = gn.topic_headlines('business')
headquaters = gn.geo_headlines('San Fran')
# search for the best matching articles that mention MSFT and # do not mention AAPL (over the past 6 month search = gn.search('MSFT -APPL', when = '6m')
Was this page helpful?