-
Notifications
You must be signed in to change notification settings - Fork 382
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No currency provided when using investpy.search_quotes() and then .retrieve_historical_data #181
Comments
Closed: Added a comment to #172 |
Hi again @Fetix! 🤗 I've already implemented a function to retrieve the default currency of every >>> import investpy
>>> search_result = investpy.search_quotes(text='apple', n_results=1)
>>> print(search_result)
{"id_": 6408, "name": "Apple Inc", "symbol": "AAPL", "country": "united states", "tag": "/equities/apple-computer-inc", "pair_type": "stocks", "exchange": "NASDAQ"}
>>> currency = search_result.retrieve_currency()
>>> print(currency)
USD
>>> print(search_result.default_currency)
USD Also see below that it's pretty simple but efficient and the elapsed time to retrieve the currency is less than 300ms, which is something nice too! /workspace/investpy $ time python -c "import investpy;data = investpy.search_quotes('apple', n_results=1);curr = data.retrieve_currency()"
real 0m1.384s
user 0m0.841s
sys 0m0.736s
/workspace/investpy $ time python -c "import investpy;data = investpy.search_quotes('apple', n_results=1)"
real 0m1.094s
user 0m0.824s
sys 0m0.871s |
It seems that as it happened before with Hopefully the current version I developed for |
Hi @Fetix, the new release is already out! 🔥 You can already install it using either For more information about this new release, you should check investpy v1.0.7 Release 🎈 |
H there,
really, really like investpy :-))
I recently asked investing to add an ETF (IE00BFNM3P36) (which they did).
For this one I can't retrieve information using get_etf_historical_data . Your proposed workaround (#148) using the developer version of investpy and investpy.search_quotes() and .retrieve_historical_data works to get the data however the course data is missing their currency (which get_etf_historical_data provides if it finds the product of interest)
Will I be able to retrieve the new ETF's data using get_etf_historical_data after the etfs.csv has been updated the next time?
I really like that using search_quotes() and retrieve_historical_data from the developer version does not require you to run different commands to retrieve data for etfs, stocks, .... but is there a way to obtain the currency information? As far as I see neither search_quotes() nor .retrieve_historical_data return it. This would be awesome.
Best,
Fetix
The text was updated successfully, but these errors were encountered: