2018 release: Slow xlsread
7 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
It seems that the xlsread function has slowed down considerably in the 2018 releases of MATLAB. Is this a known issue? Are there plans to improve it?
3 comentarios
Jan
el 15 de En. de 2019
Editada: Jan
el 15 de En. de 2019
The public forum has no knowledge about what MathWorks plans to modify in the future. Did you contact them already directly?
If the relative time of import and computing has changed, maybe R2018b computes much faster, while xlsread stayed at the same speed. Please clarify te details. Run some tests with importing the files under te different releases. An impression about the "relative speeds" of processing a data import does not allow to draw unique clues aboud the absolute times.
Respuestas (3)
Guillaume
el 15 de En. de 2019
I'm just curious is something was changed internal to the xlsread function
It's not something that can be answered by us. We're generally not told about what goes on internally at Mathworks and even if we were it would most likely be covered by a non-disclosure agreement. As Jan said, for this sort of questions you're better off asking Mathworks support directly.
I note that you use the 'basic' mode of xlsread. This mode uses an internal parser developed by mathworks (I assume), it does not rely at all on Excel to obtain the data (so whether MSoffice is installed doesn't actually matter). It's very much possible that Mathworks have made some change to that parser (probably to make it more reliable which maybe would make it slower) particularly as it looks like it will become the default mode for readtable in a future release. See the release notes about functionality change of UseExcel. But again, that's all conjecture, contact Mathworks to know for sure.
0 comentarios
Jeremy Hughes
el 15 de En. de 2019
Is this happening with all files?
You should contact MathWorks support and include an example file for which reading has slowed down.
Also, do try READTABLE with the UseExcel=false setting. For many files, this is much faster as it doesn't launch the excel process.
0 comentarios
Ryan Jones
el 7 de Oct. de 2019
I'm not sure why it may of slowed down, but I can say that for me it was much faster to use readtable with opts. In my case I was only reading a single cell located in the same place in many sheets.
opts = spreadsheetImportOptions('Sheet',1,'DataRange','B3:B3');%I put opts outside of my for loop
a = readtable(filetoread(i),opts,'useexcel',false);
myCellArray{i}= a.Var1{1}
vs
[~,~,tempCellArray] = xlsread(filetoread(i),1,'b3:b3','basic');
I did the above operations on 131 Files. readtable took 124s and xlsread took 716s
0 comentarios
Ver también
Categorías
Más información sobre Startup and Shutdown en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!