Extracting specific data from multiple excel files to create a single excel file on MAC
6 次查看(过去 30 天)
显示 更早的评论
Hi all I have a folder on my computer with 300 excel files and I don't want to manually extract the middle row from every excel file manually and combine into a single excel file. The rows differ in each file ranging from 4-6, if the row amount is 4 I would like to get the second row.
I was wondering how I can do this on Matlab through reading every Excel file in that specific file and taking out all of the columns from the middle row and then combining all that into a excel file?
I feel like some of the fucntions on a mac are limited compared to a PC.
Thanks in advance for the help!
0 个评论
回答(1 个)
Image Analyst
2022-7-19
Try the FAQ:
In the middle of the loop, use readmatrix to read in the file and then extract the row(s) you want into a new array. Then after the loop, write out the new array with writematrix
Write back if you can't figure it out and attach a couple of your workbooks with the paperclip icon after reading this:
13 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Data Import from MATLAB 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!