Extracting specific data from multiple excel files to create a single excel file on MAC

6 visualizzazioni (ultimi 30 giorni)
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!

Risposte (1)

Image Analyst
Image Analyst il 19 Lug 2022
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 Commenti
Random User
Random User il 10 Ott 2022
Sorry to clarify - what I mean is to take out not to draw back.
In the orginal question we took out the middle row and now instead of the middle row I would like to retrieve the row with the lowest CSA and combining this for all the files in another excel spreadsheet.
When we open data 1. these are the headings
Sample CSA (mm^2) Minor (mm) Major (mm) Circularity
for the third column CSA I would like to find the minimum value and then save it into another excel file. In the same manner that we answered this question.

Accedi per commentare.

Categorie

Scopri di più su Data Import from MATLAB in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by