XLsread gives interger instead of double numbers
08:34 18 Apr 2026

I use Octave 9.4.2 under Windows 10 Pro and have the following problem. I have an Excel file that contains numeric values (integer and double format) and text. I need to load the values later in a structure for calculations, but in the moment I just represent them as a table to check them.
I have some code — using lsread—to read the Excel file (datendatei contains the valid path) and to load it as follows. The file was found, and I got output from my Excel file.

 [num, txt, raw] = xlsread(datendatei, blatt);
raw{6, 6}
num(6, 6)

The sheet and line were correct. However, the output was always wrong. Whatever I did, the double numbers—formatted as numbers in Excel and read by xlsread—result in integer numbers: 40.00 gives 4000 (with num() and with raw{} 6.517 gives 6517, 6.51 gives 651, etc.
I cannot change the format to string because the values are mostly calculated inside the Excel file. For my later calculations I also need the values as numbers in the structure. I tried the following changes:

The standard decimal separator on my German Windows is ".". It is not taken from the OS. However, I also changed the decimal separator in "options" from Excel from "Locale" (German) comma "," to point "." and back.

I took the values from "num" instead of "raw.
I tried to set another locale in Octave, but "Locale" was not recognized.

I used a special function distinguishing strings and numerics. I always got the same result.

Neither Claude nor ChatGPT could help. Either their code to replace readxls did not work at all or it needs further debugging, I don't have the time for.

Why doesn't the function work like it should?

I couldn't find any posting reporting the same problem.

xlsread