Best way to load c type hexidecimal data

1 view (last 30 days)
Hi,
is there an efficient method for loading c type hexidecimal data (e.g. 0x1.db0c0cp+3) from a text file? I need to load 2 dimensional data containing 5 columns of this type of data.
Using the "load" command from matlab on linux systems (either SLED 11 or Fedora 23 64 bit based) misreads the above number as 15.3452-- it should be 14.8452. Specifically creating a text file containing only the hex number above and then using load to open the text file in matlab gives the misread result. Windows based systems just load the data as zeros.
I have written a function which correctly parses the numbers, having opened the data using fopen, but it is painfully slow for large files (likely due to my poor coding).
Are there any alternative methods?
thanks
Mike

Answers (0)

Community Treasure Hunt

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

Start Hunting!