Write a string to hdf5 file with defined string length
古いコメントを表示
I am trying to write a string to hdf5 file:
h5create('combo.hdf5','/description',1,Datatype='string');
h5write('combo.hdf5','/description',"this is the description");
When I read it out using h5disp, the result is:
Dataset 'description'
Size: 1
MaxSize: 1
Datatype: H5T_STRING
String Length: variable
Padding: H5T_STR_NULLTERM
Character Set: H5T_CSET_UTF8
Character Type: H5T_C_S1
ChunkSize: []
Filters: none
FillValue: ''
Notice the String Length is denoted as 'variable'. What if I want to define the length of this string (23 here), so it shows:
String Length: 23
Thank you very much!
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で HDF5 Files についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!