xlsread function: How to only get certain info from Excel Spreadsheets?
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Anne Nguyen
am 27 Okt. 2019
Beantwortet: Walter Roberson
am 27 Okt. 2019
Hello, how do only get certain parts of an Excel Spreadsheet onto a MATLAB script? For example, I only want to include cells G2:W2 from the spreadsheet, (which is just a fake answer key for a multiple-choice part of a given quiz), so how do I do this? I know that I have to use the xlsread function. What I have so far is:
[num,txt,raw] = xlsread(quiz_results.xslx')
Thank you!
0 Kommentare
Akzeptierte Antwort
Walter Roberson
am 27 Okt. 2019
>> help xlsread
xlsread Read Microsoft Excel spreadsheet file.
[NUM,TXT,RAW]=xlsread(FILE) reads data from the first worksheet in the Microsoft
Excel spreadsheet file named FILE and returns the numeric data in array NUM.
Optionally, returns the text fields in cell array TXT, and the unprocessed data
(numbers and text) in cell array RAW.
[NUM,TXT,RAW]=xlsread(FILE,SHEET) reads the specified worksheet.
[NUM,TXT,RAW]=xlsread(FILE,SHEET,RANGE) reads from the specified SHEET and RANGE.
Specify RANGE using the syntax 'C1:C2', where C1 and C2 are opposing corners of
the region. Not supported for XLS files in BASIC mode.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Spreadsheets finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!