Add columns to stocks/search (#5565)

* Add columns to `stocks/search`

isin, cusip, figi, composite_figi, shareclass_figi

* Update test_search[False].txt

* Update test_search[True].txt

* Delete tests/openbb_terminal/stocks/cassettes/test_stocks_helper/test_search.yaml

* Create test_search.yaml

---------

Co-authored-by: Danglewood <85772166+deeleeramone@users.noreply.github.com>
This commit is contained in:
Adwait
2023-10-18 10:18:24 +05:30
committed by GitHub
parent f1c368b906
commit 8f42c2fae8
4 changed files with 234951 additions and 222608 deletions

View File

@@ -206,6 +206,11 @@ def search(
"industry_group",
"industry",
"exchange",
"isin",
"cusip",
"figi",
"composite_figi",
"shareclass_figi",
]
]
@@ -223,7 +228,21 @@ def search(
for x in v:
exchange_suffix[x] = k
df = df[["name", "country", "sector", "industry_group", "industry", "exchange"]]
df = df[
[
"name",
"country",
"sector",
"industry_group",
"industry",
"exchange",
"isin",
"cusip",
"figi",
"composite_figi",
"shareclass_figi",
]
]
# To automate renaming columns
df.columns = [col.replace("_", " ") for col in df.columns.tolist()]
df = df.fillna(value=np.nan)

File diff suppressed because it is too large Load Diff

View File

@@ -1,2 +1,2 @@
symbol name country sector industry group industry exchange
0 MSFT Microsoft Corporation United States Information Technology Software & Services Software NMS
symbol name country sector industry group industry exchange isin cusip figi composite figi shareclass figi
0 MSFT Microsoft Corporation United States Information Technology Software & Services Software NMS US5949181045 594918104 BBG000BPHFS9 BBG000BPH459 BBG001S5TD05

View File

@@ -1,2 +1,2 @@
symbol name country sector industry group industry exchange
0 MSFT Microsoft Corporation United States Information Technology Software & Services Software NMS
symbol name country sector industry group industry exchange isin cusip figi composite figi shareclass figi
0 MSFT Microsoft Corporation United States Information Technology Software & Services Software NMS US5949181045 594918104 BBG000BPHFS9 BBG000BPH459 BBG001S5TD05