gpt4 book ai didi

How to get China Stock Market Index (SSE) in Google Sheets using GOOGLEFINANCE?(如何使用GOOGLEFINANCE在Google Sheet中获取中国股票市场指数(SSE)?)

转载 作者:bug小助手 更新时间:2023-10-25 16:37:19 31 4
gpt4 key购买 nike



I have searched everywhere but didn't find a way for this.
It's for =Googlefinance("ticker"), Is china's SSE index available as a ticker for google finance, to be used in google sheets?

我到处都找过了,但还是找不到办法。这是为了=谷歌金融(“股票代码”),中国的上交所指数是否可以作为谷歌金融的股票代码,用于谷歌表格?


更多回答
优秀答案推荐

did you try:

你试过了吗:


=GOOGLEFINANCE("SSE", "price")

=GOOGLEFINANCE("SSE", "all", TODAY()-7, TODAY(), "daily")

=GOOGLEFINANCE("SSE", "price", TODAY()-7, TODAY(), "daily")

enter image description here




or perhaps:

或者,也许:


=GOOGLEFINANCE("LON:SSE", "price")

=GOOGLEFINANCE("LON:SSE", "all", TODAY()-7, TODAY(), "daily")

0




UPDATE:


=REGEXEXTRACT(QUERY(IMPORTXML("https://finance.yahoo.com/quote/000001.SS/", "//*"), 
"where Col1 contains '000001.SS - SSE' limit 1 offset 2", 0), "\d+,\d+\.\d+")*1

0


or other source:

或其他来源:


=IMPORTXML("https://www.bloomberg.com/quote/SHCOMP:IND/", 
"//span[@class = 'priceText__1853e8a5']")*1

0



GOOGLEFINANCE is only available in English and does not support most international exchanges.

GOOGLEFINANCE仅提供英文版本,不支持大多数国际交换。


https://support.google.com/docs/answer/3093281?hl=en

Https://support.google.com/docs/answer/3093281?hl=en



add sheets extension func

添加图纸扩展功能


function yahooF(ticker) {

const url = `https://finance.yahoo.com/quote/${ticker}?p=${ticker}`;

const res = UrlFetchApp.fetch(url, {muteHttpExceptions: true});

const contentText = res.getContentText();

const price = contentText.match(/<fin-streamer(?:.*?)active="">(\d+[,]?[\d\.]+?)<\/fin-streamer>/); console.log(price[1]); return price[1];

}

enter image description here
ref: https://www.lido.app/tutorials/yahoo-finance-google-sheets

参考:https://www.lido.app/tutorials/yahoo-finance-google-sheets


更多回答

The one I am referring to is SSE Composite Index (China). The one shown in your example is a company in scotland. Current value of SSE Composite is 2660.xx

我指的是上证综指(中国)。您的示例中显示的是苏格兰的一家公司。上证综指现值为2660.xx

@TheOnlyAnil I see, try the last one. answer updated

@TheOnlyAnil我看到了,试试最后一个。答案已更新

Thanks for your answer but I am trying to generate data from googlefinance using other params too like start date, end date and interval. That way it gets date wise data for me, automatically.

谢谢你的回答,但我正在尝试使用其他参数从谷歌金融生成数据,如开始日期、结束日期和间隔。这样一来,它就会自动为我获取日期智能数据。

well if you are after historical data of OHLCV by date then scrapping it from yahoo is still possible

好吧,如果你正在寻找OHLCV的历史数据,那么从雅虎上删除它仍然是可能的

should be SHA:000001 but it does not work in GS: i.stack.imgur.com/W5KJq.png

应该是sha:000001,但在gs:i.stack.imgur.com/W5KJq.png中不起作用

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com