Datafeed problem - yahoo finance cant find stock ?
3 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
I am trying to get data on a bunch of danish stocks, fx. the Ap Moeller Maersk B stock. I am using the code
C = yahoo;
name = 'MAERSK-B.CO';
Price.(name) = fetch(C,name,'Adj Close',startDate,endDate,'d');
But am receiving an error, the problem i think is with the name, though i found it on the yahoo finance webpage it seems odd when compared to the tickers i have that does work (like 'CABGY' for carlsberg fx.)
1 Commento
Kevin Connor
il 7 Nov 2013
dftool statement will enable a GUI from which these stocks an be downloaded. I have same issue with Australian stocks ( eg BHP.AX ) where the fetch statement appears not to recognize a stock ticker with a ".xx" type extension.
Risposte (1)
Kawee Numpacharoen
il 2 Nov 2016
The problem is not in the fetch function, but in the struct's name. You can easily fix it here:
C = yahoo;
name = 'MAERSK-B.CO';
name2 = strrep(name, '.', '_')
name2 = strrep(name2, '-', '_')
Price.(name2) = fetch(C,name,'Adj Close',today-10,today,'d');
0 Commenti
Vedere anche
Categorie
Scopri di più su Web Services in Help Center e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!