필터 지우기
필터 지우기

How to read specific value from the hdf5 file.

조회 수: 5 (최근 30일)
MakM
MakM 2022년 8월 15일
편집: MakM 2022년 8월 16일
I have hdf5 file, with the contents showns:
data = h5read('check_v1_c1.h5','/coordinates',[1.00 1.00],count)
data(:,:,1) =
1193262 1193267 1193277 1193287 1193297
data(:,:,2) =
0.1737 0.1741 0.1749 0.1759 0.1770
data(:,:,3) =
0.0314 0.0318 0.0326 0.0336 0.0346
I want to extract the values of data(:,:,1),data(:,:,2) and data(:,:,3), based on the values of data(:,:,1). Like for example, how can I extract the data data(:,:,1) between 1193267 to 1193287 so my output would be something like this:
data(:,:,1) 1193267 1193277 1193287
data(:,:,2) 0.1741 0.1749 0.1759
data(:,:,3) 0.0318 0.0326 0.0336
  댓글 수: 2
dpb
dpb 2022년 8월 15일
What does
whos data
return after the first code line?
MakM
MakM 2022년 8월 16일
편집: MakM 2022년 8월 16일
Name Size Bytes Class Attributes
data 1x5x3 120 double

댓글을 달려면 로그인하십시오.

채택된 답변

Walter Roberson
Walter Roberson 2022년 8월 15일
That facility is not available for HDF.
You can modify the count to 1 for the third dimension to read in only (:, :, 1). Then you can examine those to locate portions of interest and go back to read the variable with appropriate start and count for the subsection.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 HDF5에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by