Receiving NaN's instead of values in select excel imports (script issue)
1 次查看(过去 30 天)
显示 更早的评论
Hi, I am trying to extract mean eigenvalues and vectors for spinel grains in rock samples I am studying.
When I import (all as numerical matrices) the .xlsx sheets with less rows (up to 961 rows) it works fine. Anything higher (next highest has 1223 rows) spits out NaN's. Workflow up to this point has been the same. Any help appreciated.
I just need to do
x=spinelMean(AA) **I've been calling the imports AA** and I should get a 3x3 matrix of values.
Thanks in advance.
1 个评论
Dyuman Joshi
2023-9-4
编辑:Dyuman Joshi
2023-9-4
"When I import (all as numerical matrices) the .xlsx sheets with less rows (up to 961 rows) it works fine. Anything higher (next highest has 1223 rows) spits out NaN's."
How are you importing the data?
It's working fine with readtable
回答(1 个)
Yash
2023-9-12
Hi Julian,
As I can understand, you are encountering issues with importing the data. In general, '.xlsx' files are imported into tables using the "readtable()" function. I have made an attempt to read the data provided in your query using the "readtable()" function, and it is functioning correctly. You can find more details about the "readtable()" function by visiting the following documentation link:
Additionally, you may find the article below helpful, as it provides various methods for reading spreadsheets into tables:
I hope the provided information helps in resolving the issue.
If the issue still persists, for better understanding of the issue, I suggest you share the code you are using to import the sheets. I am not able to reproduce the issue at my end because there is an unknown function in the "spinelMean.m" file named "logEFromSpinel". Any information related to the definition of this function would help me to resolve the issue.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!