loadcell.m

版本 1.1.0.0 (3.8 KB) 作者: Amos Storkey
Loads character seperated data with variable length lines and mixed types.
11.6K 次下载
更新时间 2010/1/13

查看许可证

Load any text-based data into MATLAB.

Loads data into cell array. Data can have variable length lines or be mixtures of numeric and string types.

eg.
[a,b,c]=loadcell(fname,[',' char(9)],'"','single-empty2num')

Will load tab or comma seperated values into a. Seperators lying between inverted comma pairs will be ignored. Repeated seperators will not be treated as one. All empty fields will be treated as numeric zeros rather than empty strings. b and c give further info. See help.

Other files:

celltonumeric.m will take a columnar cell array and map it to an entirely numeric array with numeric pointers into string arrays. Useful for actually doing stuff with the data you loaded!

datato1ofm.m will remap categorical data (e.g. that produced by celltonumeric) and represent it entirely as 1ofM binary data. It keeps track of what came from where so can be used form multinomial analysis too. Ideal for any count-based probabilistic analysis.

引用格式

Amos Storkey (2024). loadcell.m (https://www.mathworks.com/matlabcentral/fileexchange/1965-loadcell-m), MATLAB Central File Exchange. 检索来源 .

MATLAB 版本兼容性
创建方式 R12
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Characters and Strings 的更多信息
致谢

启发作品: readtext

Community Treasure Hunt

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

Start Hunting!
版本 已发布 发行说明
1.1.0.0

Minor updates to enhance speed.

1.0.0.0