Auto-generated import data script does not run
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Fernando Tomasel
el 21 de Mayo de 2018
Comentada: Ameer Hamza
el 22 de Mayo de 2018
Hi,
I'm using the import tool to import some data. The import tool works just fine, but the automated script it generates (attached) throws an error that seems to be related to its syntax:
"Undefined function or variable 'raw'.
Error in Untitled2 (line 38)
rawStringColumns = string(raw(:, [1,2,3,4,5,6,7,8,9,10,11,12,13,14]));"
Can you please check and tell me what may be going on?
Thx!
0 comentarios
Respuesta aceptada
Ameer Hamza
el 21 de Mayo de 2018
The file you attaches has a difference from the script file uiimport tool generate for automatically loading data from a general type of file. The file should have few lines before
numericData = NaN(size(dataArray{1},1),size(dataArray,2));
defining the raw variable. Are you sure you haven't accidentally deleted those lines? Try generating the script again.
2 comentarios
Fernando Tomasel
el 21 de Mayo de 2018
Editada: Walter Roberson
el 21 de Mayo de 2018
Ameer Hamza
el 22 de Mayo de 2018
That's true, I just tested and found this issue in R2017b that if all columns are categorical, these lines are skipped. This might some bug. R2018a produce a correct script file.
Más respuestas (0)
Ver también
Categorías
Más información sobre Data Import and Export 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!