Effacer les filtres
Effacer les filtres

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

2 vues (au cours des 30 derniers jours)
Emily Lubicich
Emily Lubicich le 19 Oct 2016
Commenté : dpb le 20 Oct 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 commentaires
Emily Lubicich
Emily Lubicich le 20 Oct 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 le 20 Oct 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?

Connectez-vous pour commenter.

Réponses (1)

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

Catégories

En savoir plus sur Large Files and Big Data dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by