Increasing Buffersize while importing data
5 次查看(过去 30 天)
显示 更早的评论
I am importing data from txt file to matlab.But the programmme gives error:"Buffer overflow (bufsize = 4095) while reading string from" I am using textscan command in the programme.So buffer size should be increased.how?
0 个评论
回答(1 个)
per isakson
2012-9-14
Hint:
textscan( ..., 'BufSize', new_size )
See the help.
6 个评论
per isakson
2012-9-14
编辑:per isakson
2012-9-14
Do you know how many disks you need to store a file of the size, 10^999 bytes? 10^999 is not exactly "multiply by ten".
How large is the file on disk? You do not need a buffer larger than the file!
Did you try
str = fileread( file_spec );
ix = strfind( str, char(10) );
mx = max( ix );
add
sz = size( str )
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Text Files 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!