Skip to content

Instantly share code, notes, and snippets.

@PatrickAlphaC
Created February 11, 2020 17:27
Show Gist options
  • Save PatrickAlphaC/2c23cb69de01b8ac9c0708b63cc9ddd0 to your computer and use it in GitHub Desktop.
Save PatrickAlphaC/2c23cb69de01b8ac9c0708b63cc9ddd0 to your computer and use it in GitHub Desktop.
Get a list of NASDAQ tickers
import requests
url = "http://ftp.nasdaqtrader.com/dynamic/SymDir/nasdaqlisted.txt"
response = requests.get(url)
tickers = [line.split("|")[0] for line in response.text.split("\n")][1:-2]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment