Info

La pregunta está cerrada. Vuélvala a abrir para editarla o responderla.

Trying to generate a plot from an Excel file.

1 visualización (últimos 30 días)
Morgan Rupard
Morgan Rupard el 24 de Feb. de 2015
Cerrada: MATLAB Answer Bot el 20 de Ag. de 2021
Hello all! I am trying to take some imported data from an excel file (.xls) in order to generate a plot of it where the x-axis is the A column and the y-axis is B-column.
Here is the code:
filename = 'PlotCycles.xls';
sheet = 1;
xlRange = 'A1:A1430';
ylRange = 'B1:B1430';
x = xlsread(filename, sheet, xlRange);
y = xlsread(filename, sheet, ylRange);
Plot(x,y)
I am getting an error that says "Warning: Could not start Excel server for import, 'basic' mode will be used. Refer to HELP XLSREAD for". This is fine I think because I only want a numerical array anyways. The next error I get is:
"In xlsread at 187
In PlotCycles at 5
Warning: Range cannot be used in 'basic' mode. The entire sheet will be loaded.
In xlsread at 200
In PlotCycles at 5
Error using xlsread (line 247)
File contains unexpected record length. Try saving as Excel 98.
Error in PlotCycles (line 5) x = xlsread(filename, sheet, xlRange);"
I'm really not sure what to do in this situation, I'd appreciate any input thanks!

Respuestas (0)

La pregunta está cerrada.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by