在哪裡可以下載在紐約證券交易所,納斯達克和美國證券交易所交易的所有普通股清單?


67

我有一個非常基本的數據問題:如何獲取在紐約證券交易所,納斯達克和美國證券交易所交易的所有普通股的清單?我將需要能夠獲得Telechart中可用的普通股的近似列表...例如,我無法在eoddata處獲得此數據...

我想計算市場廣度指標,並想知道有多少普通股交易上漲或下跌了4%(突破/細分)(Cl-Lag(Cl)> 0.04(突破4%),Cl-Lag(Cl)<-0.04(細分為4%)),則本季度有多少普通股交易量下降/上升了25%,等等。

我的第一個問題是如何獲取僅包含普通股(沒有ETF)的交易品種列表。

20

Bloomberg Open Symbology has this list. Look in the Common Stock precanned file. This will have a bit more data than you probably need as it has a separate entry and unique id for each place an equity is traded. However it is probably the highest quality list available for free anywhere.

As for filtering ETFs are broken out in a separate file (Equity_ETP) so you simply need to filter by exchange.

Update November 2017: BSYM is no more and its replacement does not have prebuilt files as far as I can tell.


10

You can download all stocks on the three exchanges listed in your question from the NASDAQ website: http://www.nasdaq.com/screening/company-list.aspx.

It looks like removing those entries with an industry of "N/A" will eliminate ETFs and other funds from the list.


9

The stockSymbols function in the R package TTR pulls the data from nasdaq.com that @bellamyj mentioned. It also attempts to convert the symbols to a format acceptable to Yahoo Finance.

That said, I'm not certain how to filter this list for only common stocks. There are 1275 securities with "n/a" Sector or Industry, leaving ~5000. Perhaps the remaining categories in Sectors and Industries can help you further refine the list.


82

NASDAQ makes this information available via FTP and they update it every night. Log into ftp.nasdaqtrader.com anonymously. Look in the directory SymbolDirectory. You'll notice two files: nasdaqlisted.txt and otherlisted.txt. These two files will give you the entire list of tradeable symbols, where they are listed, their name/description, and an indicator as to whether they are an ETF.

Given this list, which you can pull each night, you can then query Yahoo to obtain the necessary data to calculate your statistics.

UPDATE: More information about these files and their fields can be found here.


-3

easy2data financial section With list of hang seng companies,nasdaq companies,cac 40 companies, S&P asia 50 companies etc...


20

Slightly ugly bash one-liner for a sorted JSON array:

echo "[\"$(echo -n "$(echo -en "$(curl -s --compressed 'ftp://ftp.nasdaqtrader.com/SymbolDirectory/nasdaqlisted.txt' | tail -n+2 | head -n-1 | perl -pe 's/ //g' | tr '|' ' ' | awk '{printf $1" "} {print $4}')\n$(curl -s --compressed 'ftp://ftp.nasdaqtrader.com/SymbolDirectory/otherlisted.txt' | tail -n+2 | head -n-1 | perl -pe 's/ //g' | tr '|' ' ' | awk '{printf $1" "} {print $7}')" | grep -v 'Y$' | awk '{print $1}' | grep -v '[^a-zA-Z]' | sort)" | perl -pe 's/\n/","/g')\"]"


EDIT: Filtered out test stocks