필터 지우기
필터 지우기

Plot or variables window?

조회 수: 1 (최근 30일)
zdarova_koresh
zdarova_koresh 2020년 8월 2일
편집: zdarova_koresh 2020년 8월 5일
I'm using Matlab R2017a to create a dataset consisting of several netcdf files for using them in an algorithm written in Python later.
When checking the orientation of an array I found a strange issue, I don't know if it is a bug or no. The problem is that the results of viewing the array through the variables window and plotting them are mirror images of each other. I attach two pictures below to show the issue.
Variables window (I just copied the values and pasted them into Excel to illustrate them better).
Plot (contorf).
Which representation is the correct one? How to check it? It is really important for my project.
I attached the zip file with an example netcdf file and the code to extract the variable from the figures shown.
swh=ncread('interim1.nc','swh');
swh1=squeeze(swh(:, : ,1));
swh1=rot90(swh1);

답변 (1개)

zdarova_koresh
zdarova_koresh 2020년 8월 5일
편집: zdarova_koresh 2020년 8월 5일
Supposedly, matlab mirrors the data when using countorf.
Here I created 10х10 identity matrix and tried to plot it.

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by