matio icon indicating copy to clipboard operation
matio copied to clipboard

string array support ?

Open Nelson-numerical-software opened this issue 6 years ago • 7 comments

reading a v7.3 or v6 matfile with A = ["Nelson" "is" "open"] returns MAT_T_UNKNOWN (tested with matio master)

A = ["Matio" "string" "array"]
save('string_array.mat', 'A', '-v7.3')

What are really supported types ? My Soft nelson can have all equivalent variables available in mat file and I would like to use matio...

Thanks

How and in which MATLAB version did you generate this MAT-file?

tbeu avatar Feb 15 '19 19:02 tbeu

do you support string array ?

Yes, character array is supported.

tbeu avatar Feb 15 '19 20:02 tbeu

string array != character array since 2016 string is available. It is as a cell of characters https://fr.mathworks.com/help/matlab/ref/string.html support or not ?

Not yet supported. Let me see what I can do.

Can you save your MAT file also as v7 and v6 please.

tbeu avatar Feb 15 '19 20:02 tbeu

string_array = ["Matio" "will" "support"; "string" missing() "array"] 
save('d:/string_array-v7.3.mat','string_array','-v7.3')
save('d:/string_array-v7.mat','string_array','-v7')
save('d:/string_array-v6.mat','string_array','-v6')

Related to #77 and the undocumented opaque type for MCOS. At least, we have the reverse engineering available by @mbauman at https://nbviewer.jupyter.org/gist/mbauman/9121961.

tbeu avatar Feb 15 '19 21:02 tbeu