I have been struggling for over an hour, reading documentation, experimenting, google searching for information on how to ask for the closing price of the NASDAQ index. I don't want a stock on that index, I want the daily closing prices of the index itself. No stock name, no entity, no entity class that I have tried seems to work. Is this even possible?
Asked
Active
Viewed 243 times
2
2 Answers
2
Tickers with a caret don't always work. But I think your post from 2020 is moot now, FinancialData["^IXIC"] works just fine in 13.3 on Linux.
I find the Yahoo Finance data API quite reliable and fast, have a look at
now=Round@AbsoluteTime[Date[]]-AbsoluteTime[{1970,1,1,0,0,0}];
Import["https://query1.finance.yahoo.com/v7/finance/download/^IXIC?period1=1410825600&period2="<>ToString[now]<>"&interval=1d&events=history&includeAdjustedClose=true"]
Andreas Lauschke
- 4,009
- 22
- 20
0
As of version 13.1 this works:
(* get timeseries *)
nasdaq = FinancialData["^IXIC", "Close", {{2018, 1, 1}, {2022, 11, 03}}];
To get the daily closing prices you can do nasdaq["Values"]
You can also opreate directly on the TimeSeries
(*check most recent data*)
nasdaq["LastDate"] (* DateObject[{2022, 11, 2, 0, 0, 0}, "Instant", "Gregorian", 0.]*)
nasdaq["LastValue"] (* 10524.8 *)
(annualised vol)
16StandardDeviation@Differences@Log@nasdaq ( 0.267453 *)
(eye ball your data)
DateListPlot[nasdaq]
IntroductionToProbability
- 2,134
- 6
- 22

FinancialData["^IXIC"]but it does not. There are a lot of issues withFinancialData. e.g. see this. – Rohit Namjoshi Mar 03 '20 at 20:44