google-finance

How can I trigger an event when this span value changes?

对着背影说爱祢 提交于 2021-02-04 18:39:25
问题 I'm trying to get a console log when the price of the current page's stock changes. page: https://www.google.com/finance?q=NASDAQ%3AGOOG&ei=yvbRVbHSCcKgmAGyu7CoDA Element ID: #price-panel > div > span > span Attempt 1: fail $("#price-panel div span span").onchange = function() { console.log('change')} Attempt 2: fail document.getElementById('price-panel').children[0].children[0].onchange = function() { console.log('change')} builtwith.com says the javascript is the "google api" which is

Get exchange rate on a specific date from GoogleFinance

一曲冷凌霜 提交于 2020-01-13 08:49:09
问题 I'm having trouble stopping the googlefinance function on a specific date to use "that" specific exchange rate to convert currency from GBP to EUR. Here is my formulae: =Finance!B4*GOOGLEFINANCE("CURRENCY:GBPEUR","price",date(2017,15,11)) Here is the error: When evaluating GOOGLEFINANCE, the query for the symbol: 'CURRENCY:GBPEUR' returned no data. I've looked at other solutions on SO but none to avail. I've actually added "date" and "price" to my formulae from other solutions. Like so:-

Error in Google finance API

假如想象 提交于 2020-01-10 04:31:30
问题 I want to convert currencies using google finance api. But its not working in my local machine(India). It works fine when I hit from one server located in USA and provides proper result. Url : https://finance.google.com/finance/converter?a=1&from=ZAR&to=USD&meta=53336452-3e60-4fa1-9740-9ef8ea9e9118 Can anyone please help me to work this api properly in my local machine? Any help will be appriciated Thanks. 回答1: I was facing the similar issue ( Google Converter API suddenly not working ) As

HTTP Error 404 from googlefinance in python 2.7

▼魔方 西西 提交于 2019-12-30 05:00:22
问题 In python 2.7 shell I ran the follwoings: $from googlefinance import getQuotes $import json $from urllib2 import urlopen $print json.dumps(getQuotes('AAPL'), indent=2) Got error message on the 4th command as follows: Traceback (most recent call last): Python Shell, prompt 3, line 1 File "C:\Users\mlashkar\_development\python\v2.7\Lib\site-packages\googlefinance\__init__.py", line 70, in getQuotes content = json.loads(request(symbols)) File "C:\Users\mlashkar\_development\python\v2.7\Lib\site

Download all stock symbol list of a market [closed]

人走茶凉 提交于 2019-12-29 02:56:07
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 2 years ago . I need to download in some way a list of all stock symbol of specified market. I've found in this link ho can I do it someway. It uses following link in order to retrieve stock list that statisfies some parameters: https://www.google.com/finance?start=0&num=3000&q=%5B(exchange%20%3D%3D%20%22NASDAQ%22)%20%26%20

Download history stock prices automatically from yahoo finance in python

痴心易碎 提交于 2019-12-28 07:17:48
问题 Is there a way to automatically download historical prices of stocks from yahoo finance or google finance (csv format)? Preferably in Python. 回答1: Short answer: Yes. Use Python's urllib to pull the historical data pages for the stocks you want. Go with Yahoo! Finance; Google is both less reliable, has less data coverage, and is more restrictive in how you can use it once you have it. Also, I believe Google specifically prohibits you from scraping the data in their ToS. Longer answer: This is

How to decode ¥ in JSON

假装没事ソ 提交于 2019-12-25 07:59:10
问题 I am using python to parse a JSON file, I know it is because of this ¥, that I got this error when I was using json.loads UnicodeDecodeError: 'utf8' codec can't decode byte 0xa5 in position 106: invalid start byte But how do I get around it? Do I decode and encode again? ¥ is the Chinese currency sign, but I am not sure which code category it belongs to. Thanks! update: ==================== I think my question should be, If you see this symbol, how do you guess the encoding. An answer to this

How to make google spreadsheet refresh itself every 1 minute?

痴心易碎 提交于 2019-12-21 07:03:57
问题 My google spreadsheet is using GOOGLEFINANCE('symbol','price) function to retrieve stock prices of my portfolio. Unfortunately, I have to refresh manually now. How can I make the spreadsheet refresh itself every 1 minute? Thank you for your help. 回答1: If you're on the New Google Sheets, this is all you need to do, according to the docs: change your recalculation setting to "On change and every minute" in your spreadsheet at File > Spreadsheet settings. This will make the entire sheet update

Improving a function to get stock news data from google in R

时光怂恿深爱的人放手 提交于 2019-12-20 09:24:32
问题 I've written a function to grab and parse news data from Google for a given stock symbol, but I'm sure there are ways it could be improved. For starters, my function returns an object in the GMT timezone, rather than the user's current timezone, and it fails if passed a number greater than 299 (probably because google only returns 300 stories per stock). This is somewhat in response to my own question on stack overflow, and relies heavily on this blog post. tl;dr: how can I improve this