Why are my data values reversed/swapped/transposed in HDFView?
This is primarily a programming language issue:
- If your file was created with a C program, then the data is stored with the assumption that the last dimension of the slab varies fastest ("row-major order").
- If your file was created with a F90 application, then the data is stored with the assumption that the first dimension varies fastest ("column-major order").
The data itself in HDF5 is exactly the same. HDF-Java reads the data in row-major order. If your data was written with a Fortran application, then the data will appear to be transposed in HDFView.
Since HDFView does not know how the file was created, it provides a way to swap the dimensions if need be. You can change the order that the data is read and viewed as follows:
- Select the dataset by clicking with the left mouse button.
- Then click the right mouse button and select "Open As".
- This will pop up a window. You can change what you want to see for the height, width, and depth from this page.