Borrar filtros
Borrar filtros

I am having trouble importing space delimited data from a text file.

2 visualizaciones (últimos 30 días)
Emily Lubicich
Emily Lubicich el 19 de Oct. de 2016
Comentada: dpb el 20 de Oct. de 2016
I have a relatively small text file with just two columns and it will not import. I tried using:
filename = 'unpolished_100x';
delimiterIn = ' ';
headerlinesIn = 0;
A = importdata(filename,delimiterIn,headerlinesIn);
and:
X = importdata('-pastespecial')
and I get this message:
Undefined function 'importdata' for input arguments of type 'char'.
Every time I hit "Import data" I receive this message:
com.mathworks.jmi.MatlabException: Undefined function 'uiimport' for input arguments of type 'char'.
at com.mathworks.jmi.NativeMatlab.SendMatlabMessage(Native Method)
at com.mathworks.jmi.NativeMatlab.sendMatlabMessage(NativeMatlab.java:265)
at com.mathworks.jmi.MatlabLooper.sendMatlabMessage(MatlabLooper.java:120)
at com.mathworks.jmi.Matlab.mtFeval(Matlab.java:1619)
at com.mathworks.mlwidgets.workspace.WorkspaceCommands$1.runOnMatlabThread(WorkspaceCommands.java:1246)
at com.mathworks.mlwidgets.workspace.WorkspaceCommands$1.runOnMatlabThread(WorkspaceCommands.java:1241)
at com.mathworks.jmi.MatlabWorker$2.run(MatlabWorker.java:79)
at com.mathworks.jmi.NativeMatlab.dispatchMTRequests(NativeMatlab.java:440)|||||||
  13 comentarios
Emily Lubicich
Emily Lubicich el 20 de Oct. de 2016
That data command returns: Undefined function 'dlmread' for input arguments of type 'char'.
I have restarted matlab but not the computer. I'm leaving for the day so when I start it up in the morning I will give it a try. If it doesn't work then I will contact IT on campus. They can reinstall it. Thank you both for the help!
dpb
dpb el 20 de Oct. de 2016
That sounds as though the IOFUN directory that holds all i/o routines is either missing or not in the MATLABPATH as was beginning to suspect. Probably reinstallation is going to be the only cure, but what does
path
return?

Iniciar sesión para comentar.

Respuestas (1)

Walter Roberson
Walter Roberson el 19 de Oct. de 2016
Try, in this order:
rehash toolboxcache
and
restoredefaultpath
and if neither of those helps, then reinstall MATLAB.

Categorías

Más información sobre Large Files and Big Data en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by