Anda di halaman 1dari 42

1

#Open Discussion

▸ Pengolahan Data Satelit dan Model


Cuaca Numerik Menggunakan GrADS dan
NCO

▸ Minggu, 12 Agustus 2018


2
Pendahuluan

Data Satelit???
3

Data Model Numerik???


4
Memahami isi data NetCDF
GrADS
5

The Grid Analysis and Display System (GrADS) merupakan software interaktif
yang digunakan untuk memanipulasi dan visualisasi data sains kebumian.

Mengapa harus GrADS???


 Gratis

 Direkomendasikan oleh WMO

 Mudah digunakan

 Aplikasi ringan

 Multi platform (Windows, linux, Mac OS X)


6

NetCDF Operator (NCO)


The NCO toolkit manipulates and analyzes data stored in netCDF-accessible
formats, including DAP, HDF4, and HDF5. It exploits the geophysical expressivity
of many CF (Climate & Forecast) metadata conventions and many powerful
mathematical and statistical algorithms of GSL (the GNU Scientific Library).
7
Perintah dasar GrADS
#Membuka file
sdfopen <<alamat file>> [untuk data netCDF]
open <<alamat file>> [untuk data *.dat]
run <<alamat file>> [untuk script grads (*.gs)]

#Membuka identitas data


q file

#setting variable
Setting waktu:
Set t 1
Set t 1 last
Set time 02Z01jan2018
8

Setting domain wilayah


Set lon <bujur> <bujur>
Set lat <lintang> <lintang>
Set lev <ketinggian_lapisan> (contoh, set lev 500)
Set z <ketinggian_lapisan> (contoh, set z 2)
#setting jenis tampilan
Set gxout <expresi> (contoh, set gxout shaded)

Perlu diperhatikan:
Setting tampilan bergantung pada setting domain dan setting waktu
9
Daftar ekspresi gxout
10

#memperhalus peta
set mpdset hires
#memeperhalus kontur
set csmooth on
#atur clevs
Set clevs <range>
#menampilkan data
d <nama_variable>
#Menambahkan color bar
cbar
cbarn
cbarc
11

#menambahkan judul
draw title <judul>
#menambahkan x label
draw xlab <nama_xlab>
#Menambahkan ylabel
Draw ylabel <nama_ylabel>
#Menyimpan gambar
Printim <alamat_file>
#Menghapus gambar pada display
C
12

#Mengekspor variable kedalama file netCDF baru


Set sdfwrite <alamat_file>
Sdfwrite <nama_variable>
#Menutup file
Reinit
13
Plotting data GSMap

open GSMaP_NRT.hourly.rain.ctl
set t 1
set lat -12 12
set lon 90 145
set mpdset hires
q file
#plot shaded
c
set gxout shaded
d precip
cbar
14
GSMaP kumulatif 24 jam
c
harian=sum(precip,t=1,t=24)
d harian
cbar
#atur clevs
c
set clevs 0 2 4 6 8 10 12 14 16
d harian
draw title Curah Hujan Kumulatif 24 Jam (mm)
draw xlab Bujur
Draw ylab Lintang
Printim E:\hujan.png white
15
Plot Data Angin (Shaded)

reinit
sdfopen F:\opdis\angin10m.nc
q file
set gxout shaded
set mpdset hires
set csmooth on
d mag(u10,v10)
cbar
16
Plot Vektor angin

c
set gxout vector
d u10;skip(v10,3,3)
#atur arrow
c
set arrscl 0.3 [panjang row, biasanya 0,5 - 1]
set arrowhead 0.08 [ukuran head arrow, default 0.05]
17
Gabungan Vektor+Shaded

c
d u10;skip(v10,3,3);mag(u10,v10)
cbar

#dalam knots
c
d u10;skip(v10,3,3);mag(u10,v10)*2
cbar
18
Plot Streamline
c
set gxout stream
set strmden 5
d u10;v10
#Gabungan Streamline+shaded
c
set grads off
set gxout stream
set strmden 5
d u10;v10;mag(u10,v10)*2
cbar
printim E:\stream.png white
19
Plot Wind Barb

c
set gxout barb
set mpdset hires
d u10;skip(v10,3,3)
printim E:\windbarb.png white
20
Plot Timeseries
reinit
sdfopen F:\opdis\RH.nc
q file
set lat -5
set lon 100
set t 1 23
dr
draw ylab Kelembapan Udara (%)
draw xlab Tanggal
draw title Kelembapan Udara 1-23 Januari 2018
Printim E:\Timeseries.png white
21
Plot Irisan Vertikal RH

reinit
sdfopen F:\opdis\RH.nc
q file
set z 1 9
set lev 1000 200
set lat -5
set lon 100 110
set gxout shaded
set csmooth on
dr
cbarn
22
Diagram Hovmoller
c
set lev 1000
set lat -5
set lon 100 110
set t 1 23
set gxout shaded
set csmooth on
dr
cbar
draw xlab Bujur
draw ylab Tanggal
printim E:\hovmoller_RH.png white
23
Plot Suhu Vertikal

reinit
sdfopen F:\opdis\suhuatas.nc
q file
set t 1
set z 1 9
set lon 100
set lat -2
dt
24

#konversi ke celcius
c
d t-273.15
#atau buat variabel baru
c
suhu=t-273.15
d suhu
draw title Profil Vertikal Suhu Udara
draw xlab Suhu Udara (Celcius)
draw ylab Ketinggian Lapisan (mb)
printim E:\suhuvertikal.png white
25
Mencari rata-rata dalam 1 Bulan
c
set t 1
q file
set lev 1000
set lat -12 12
set lon 90 145
bulanan=ave(t,t=1,t=31)
#atau
bulanan=ave(t,time=01jan2018,time=31jan2018)
set gxout shaded
set mpdset hires
set csmooth on
d bulanan
26
Overlay variabel dari data yang berbeda

reinit
sdfopen F:\opdis\angin10m.nc
q file 1
sdfopen F:\opdis\suhu2m.nc
q file 2
set gxout shaded
set mpdset hires
set csmooth on
d t2m.2
d u10.1;skip(v10.1,3,3)
27
Mencari nilai Bulanan selama beberapa Tahun
reinit
sdfopen F:\opdis\suhu.nc
q file
set t 1
28

define jant=ave(t2m,time=jan1987,time=dec2016,12)-273.15
define febt=ave(t2m,time=feb1987,time=dec2016,12)-273.15
define mart=ave(t2m,time=mar1987,time=dec2016,12)-273.15
define aprt=ave(t2m,time=apr1987,time=dec2016,12)-273.15
define mayt=ave(t2m,time=may1987,time=dec2016,12)-273.15
define junt=ave(t2m,time=jun1987,time=dec2016,12)-273.15
define jult=ave(t2m,time=jul1987,time=dec2016,12)-273.15
define augt=ave(t2m,time=aug1987,time=dec2016,12)-273.15
define sept=ave(t2m,time=sep1987,time=dec2016,12)-273.15
define octt=ave(t2m,time=oct1987,time=dec2016,12)-273.15
define nopt=ave(t2m,time=nov1987,time=dec2016,12)-273.15
define dect=ave(t2m,time=dec1987,time=dec2016,12)-273.15
29

set clevs 19 20 21 22 23 24 25 26 27 28 29 30
d jant
draw title Januari
cbarn
30
Eksport variabel kedalam file netCDF baru

c
set t 2
set sdfwrite E:\suhufeb.nc
sdfwrite febt
31

Latihan
Tampilkan Plot spasial data satelit pada
folder hima (1 saja)
32

Latihan 2
Tampilkan dan print semua data satelit
pada folder hima dengan format *.png
(gunakan cara se efisien mungkin)
33

#template script untuk latihan 2


reinit
sdfopen F:\opdis\hima\
set lat -12 12
set lon 90 145
set gxout shaded
set mpdset hires
d ir-273.15
cbar
draw title
printim F:\opdis\
34
Controlling Colors in GrADS
GrADS is built with 16 default colors that are used in a variety of applications. Every color in
GrADS has a unique color number that is used as an index to identify it in GrADS commands.
Complete specifications of the default colors numbered 0 to 15 are given below:
35
36
contoh define warna baru
* These are the BLUE shades
set rgb 16 0 0 255
set rgb 17 55 55 255
set rgb 18 110 110 255
set rgb 19 165 165 255
set rgb 20 220 220 255
* These are the RED shades
set rgb 21 255 220 220
set rgb 22 255 165 165
set rgb 23 255 110 110
set rgb 24 255 55 55
set rgb 25 255 0 0
37
contoh
c
set gxout shaded
set mpdset hires
set rgb 16 0 0 255
set rgb 17 55 55 255
set rgb 18 110 110 255
set rgb 19 165 165 255
set rgb 20 220 220 255
set rgb 21 255 220 220
set rgb 22 255 165 165
set rgb 23 255 110 110
set rgb 24 255 55 55
set rgb 25 255 0 0
38

set clevs -70 -60 -50 -40 -30 -20 -10 0 10 20


set ccols 16 17 18 19 20 1 21 22 23 24 25
d ir-273.15
cbarn
39
Contoh 2 : plot GSMaP dengan background putih

open GSMaP_NRT.hourly.rain.ctl
set lat -12 12
set lon 90 145
harian=sum(precip,t=1,t=23)
set gxout shaded
set mpdset hires
set clevs 0 2 4 6 8 10 12 14 16 18 20 22
set ccols 0 4 11 5 13 3 10 7 12 8 2 6 9
d harian
cbar
40
Pengayaan : Merge File menggunakan NCO

buka terminal ubuntu


masuk ke folder
angin
ketik perintah:
ncrcat 2012.nc 2013.nc 2014.nc 2015.nc 2016.nc 2017.nc gabung.nc
tekan enter
41
Referensi

http://cola.gmu.edu/grads/gadoc/
Makmur, Erwin. 2008. Panduan GrADS untuk Pemula. Jakarta: BMKG
Zender, Charlie. 2018. NCO User Guide. California: University of California
42

THANKS!
Any questions?
You can find me at 085712705701

Anda mungkin juga menyukai