Convert pixels in lat-lon to kilometer square

2 ビュー (過去 30 日間)
Joydeb Saha
Joydeb Saha 2022 年 10 月 26 日
コメント済み: Joydeb Saha 2022 年 10 月 26 日
How can I change the pixels (in lat longs) of some monthly .nc files to kilometere square for every month. Spatial resolution of the data is 0.5 x 0.625.
  2 件のコメント
KSSV
KSSV 2022 年 10 月 26 日
Read about deg2km
Joydeb Saha
Joydeb Saha 2022 年 10 月 26 日
ncFiles = dir('E:\COT Work\New\COTdata\cot2\*.nc');
N = length(ncFiles) ;
Q = zeros(N,1) ;
for i = 1:N
ncFile = fullfile(ncFiles(i).folder,ncFiles(i).name);
data_Wwind=netcdf(ncFile);
cot=data_Wwind{'M2TMNXRAD_5_12_4_TAUHGH'}(:);
th3 = cot > 3;
B = double(th3);
Q(i)=sum(B(:) == 1);
end
I writing the code here. This counts the COT values which are above 3. Then it is counts the total number of pixels which are above 3 for for every data file. Basically, I want the cot values which are above pixel 3, and convert those pixel (sum up) to area (in km square). Therefore Q shall give the monthly area values of COT which are above threshold 3. May be a little modification in the present code is needed.

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeAgriculture についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by