More advanced example

From CrewWiki

(Difference between revisions)
Jump to: navigation, search
(Display a cloud property of all algorithms on the MSG disk)
 
(24 intermediate revisions not shown)
Line 1: Line 1:
-
Go back to [[CREW_software_package | CREW software package]]
 
-
 
==Display a cloud property of one algorithm on the MSG disk==
==Display a cloud property of one algorithm on the MSG disk==
<code>
<code>
Line 11: Line 9:
</code><br>
</code><br>
[[File:single_image.png|200px|CMS cloud top height]]<br>
[[File:single_image.png|200px|CMS cloud top height]]<br>
 +
<br>
 +
 +
==Difference of one data set to another (one picture per algorithm pair)==
 +
<code>
 +
o=obj_new('cws_stats') <br>
 +
o->set_product,'ctt'<br>
 +
o->set_date,2008,6,13,12,00<br>
 +
o->diff_maps, group='AWG'<br>
 +
obj_destroy, o<br>
 +
</code><br>
 +
[[File:ctp_difference.jpg|200px|cloud top temperature difference]]
<br>
<br>
Line 22: Line 31:
</code><br>
</code><br>
[[File:group_image2.jpg|200px|overview cloud top pressure]]
[[File:group_image2.jpg|200px|overview cloud top pressure]]
 +
<br>
 +
 +
==Calculate multi algorithm ensemble average==
 +
Note, first you have to calculate the multi ensemble average with <code>o->algorithm_average(/calc, /save, mask='com')</code>. As the default resolution is a reduced resolution, you have to specify explecitely the <code>scale=1</code>, when you create the <code>cws_stats</code> object. If the average file is created, you can handle the average like a group by setting the group to 'AVG' and make plots like in the other examples (and of cause you can use the default reduced resolution again). By setting the group to 'NOBS' you can make plots of the number of algorithm observation.<br>
 +
<code>
 +
o=obj_new('cws_stats', scale=1) <br>
 +
o->set_product,'ctt'<br>
 +
o->set_date,2008,6,13,12,00<br>
 +
avg = o->algorithm_average(/calc, /save, mask='com')<br>
 +
o->set_group,'AVG'<br>
 +
o->make_image, /single<br>
 +
o->set_group,'NOBS'<br>
 +
o->make_image, /single<br>
 +
obj_destroy, o<br>
 +
</code><br>
 +
[[File:multi_algorithm_average.jpg|200px|multi algorithm average]] [[File:number_of_observations.jpg|200px|number of observations]]
 +
<br>
 +
 +
==Calculate multi algorithm ensemble standard deviation==
 +
Note, first you have to calculate (and save) the multi algorithm ensemble average like in the example before. Then you have to calculate the multi algorithm ensemble standard deviation. Like in the example before, you have to specify explecitely the <code>scale=1</code>, when you create the <code>cws_stats</code> object. If the standard deviation file is created, you can handle the absolute and relative standard deviations like a group by setting the group to 'STD_ABS' and 'STD_REL' respectively, and make plots like in the other examples (and of cause you can use the default reduced resolution again).<br>
 +
<code>
 +
o=obj_new('cws_stats', scale=1) <br>
 +
o->set_product,'ctt'<br>
 +
o->set_date,2008,6,13,12,00<br>
 +
std_abs = o->algorithm_stddev (/calc, /save, mask='com')<br>
 +
o->set_group,'STD_ABS'<br>
 +
o->make_image, /single, min=0, max=20<br>
 +
std_rel = o->algorithm_stddev (/calc, /save, mask='com', /relative)<br>
 +
o->set_group,'STD_REL'<br>
 +
o->make_image, /single<br>
 +
obj_destroy, o<br>
 +
</code><br>
 +
[[File:multi_algorithm_abs_stddev.jpg|200px|absolute multi algorithm standard deviation]] [[File:multi_algorithm_rel_stddev.jpg|200px|relative multi algorithm standard deviation]]
<br>
<br>
Line 43: Line 85:
obj_destroy, o<br>
obj_destroy, o<br>
</code><br>
</code><br>
-
[[File:cth_latitude.jpg|200px|latitudinal mean of cloud top height]]<br>
+
[[File:ctt_latitude.jpg|200px|latitudinal mean of cloud top temperature]]<br>
<br>
<br>
Line 54: Line 96:
obj_destroy, o<br>
obj_destroy, o<br>
</code><br>
</code><br>
-
[[File:single_image.png|200px|cloud top pressure histogram]]<br>
+
[[File:viewing_zenith_angle.jpg|200px|cloud top pressure per viewing zenith angle]]<br>
<br>
<br>
-
==Reading two datasets and have a look at the difference==
+
==Simple statistics as a table==
<code>
<code>
-
<nowiki>;</nowiki> define object <br>
+
o=obj_new('cws_stats') <br>
-
o=obj_new('cws_read',xrange=[1500,2800],yrange=[2800,3400],scale=0.3)<br>
+
-
 
+
-
<nowiki>;</nowiki> define date and time<br>
+
-
o->set_date,2008,6,13,12,0<br>
+
-
<nowiki>;</nowiki> read coast vector<br>
+
-
coast=o->coast_line(/vector)<br>
+
-
<nowiki>;</nowiki> set cloud property<br>
+
o->set_product,'ctp'<br>
o->set_product,'ctp'<br>
-
<nowiki>;</nowiki> set CREW algorithm<br>
+
o->set_date,2008,6,13,12,00<br>
-
o->set_group,'AWG'<br>
+
o->make_tables<br>
-
<nowiki>;</nowiki> read and display data<br>
+
obj_destroy, o<br>
-
ctp1=o->get_data()<br>
+
</code><br>
-
window,1<br>
+
[[File:ctp_table.jpg|200px|cloud top pressure statistics]]<br>
-
view2d,ctp1,/cool,/colo,no_data_idx=where(ctp1 le 0),coast_vec=coast,title='AWG ctp', min=200<br>
+
<br>
-
<nowiki>;</nowiki> read and display cloud top pressure for another algorithm<br>
+
==Two algorithm scatter plot==
-
o->set_group,'CMS'<br>
+
<code>
-
ctp2=o->get_data()<br>
+
o=obj_new('cws_stats')<br>
-
window,2<br>
+
o->set_product,'ctt'<br>
-
view2d,ctp2,/cool,/colo,no_data_idx=where(ctp2 le 0),coast_vec=coast,title='CMS ctp',min=200<br>
+
o->set_date,2008,6,13,12,00<br>
 +
o->make_corSingle<br>
 +
obj_destroy, o<br>
 +
</code><br>
 +
[[File:corSingle.jpg|200px|cloud top temperature scatter plots]]
 +
<br>
-
<nowiki>;</nowiki> display the difference of the two datasets<br>
+
==Thumbnails of all scatter plots==
-
window,3<br>
+
<code>
-
view2d,ctp1-ctp2,/cool,/colo,no_data_idx=where((ctp1 le 0) or (ctp2 le 0) or (abs(ctp1-ctp2) gt 150)),coast_vec=coast,title='difference ctp AWG-CMS',min=-150,max=150<br>
+
o=obj_new('cws_stats') <br>
 +
o->set_product,'ctt'<br>
 +
o->set_date,2008,6,13,12,00<br>
 +
o->make_corThumb<br>
 +
obj_destroy, o<br>
 +
</code><br>
 +
[[File:corThumb.jpg|200px|overview cloud top temperature correlation plots]]
 +
<br>
-
obj_destroy, o
+
==Make ISCCP like plots==
-
</code>
+
<code>
-
 
+
o=obj_new('cws_stats') <br>
-
[[File:difference_of_two_datasets.png|200px|difference of AWG and CMS cloud top pressure]]
+
o->cod_ctp<br>
 +
obj_destroy, o<br>
 +
</code><br>
 +
[[File:isccp.jpg|200px|ISCCP like CTP COD histogram]]
 +
<br>

Latest revision as of 16:10, 26 February 2014

Contents

Display a cloud property of one algorithm on the MSG disk

o=obj_new('cws_stats')
o->set_product,'cth'
o->set_group,'CMS'
o->set_date,2008,6,13,12,15
o->make_image, /single
obj_destroy, o

CMS cloud top height

Difference of one data set to another (one picture per algorithm pair)

o=obj_new('cws_stats')
o->set_product,'ctt'
o->set_date,2008,6,13,12,00
o->diff_maps, group='AWG'
obj_destroy, o

cloud top temperature difference

Display a cloud property of all algorithms on the MSG disk

o=obj_new('cws_stats')
o->set_product,'ctp'
o->set_date,2008,6,13,12,00
o->make_image, /no_track
obj_destroy, o

overview cloud top pressure

Calculate multi algorithm ensemble average

Note, first you have to calculate the multi ensemble average with o->algorithm_average(/calc, /save, mask='com'). As the default resolution is a reduced resolution, you have to specify explecitely the scale=1, when you create the cws_stats object. If the average file is created, you can handle the average like a group by setting the group to 'AVG' and make plots like in the other examples (and of cause you can use the default reduced resolution again). By setting the group to 'NOBS' you can make plots of the number of algorithm observation.
o=obj_new('cws_stats', scale=1)
o->set_product,'ctt'
o->set_date,2008,6,13,12,00
avg = o->algorithm_average(/calc, /save, mask='com')
o->set_group,'AVG'
o->make_image, /single
o->set_group,'NOBS'
o->make_image, /single
obj_destroy, o

multi algorithm average number of observations

Calculate multi algorithm ensemble standard deviation

Note, first you have to calculate (and save) the multi algorithm ensemble average like in the example before. Then you have to calculate the multi algorithm ensemble standard deviation. Like in the example before, you have to specify explecitely the scale=1, when you create the cws_stats object. If the standard deviation file is created, you can handle the absolute and relative standard deviations like a group by setting the group to 'STD_ABS' and 'STD_REL' respectively, and make plots like in the other examples (and of cause you can use the default reduced resolution again).
o=obj_new('cws_stats', scale=1)
o->set_product,'ctt'
o->set_date,2008,6,13,12,00
std_abs = o->algorithm_stddev (/calc, /save, mask='com')
o->set_group,'STD_ABS'
o->make_image, /single, min=0, max=20
std_rel = o->algorithm_stddev (/calc, /save, mask='com', /relative)
o->set_group,'STD_REL'
o->make_image, /single
obj_destroy, o

absolute multi algorithm standard deviation relative multi algorithm standard deviation

1d histogram

o=obj_new('cws_stats')
o->set_product,'ctp'
o->set_date,2008,6,13,12,00
o->hist1d
obj_destroy, o

cloud top pressure histogram

dependency on latitude

o=obj_new('cws_stats')
o->set_product,'cth'
o->set_date,2008,6,13,12,00
o->dep
obj_destroy, o

latitudinal mean of cloud top temperature

dependency on viewing zenith angle

o=obj_new('cws_stats')
o->set_product,'ctp'
o->set_date,2008,6,13,12,00
o->dep, /vza
obj_destroy, o

cloud top pressure per viewing zenith angle

Simple statistics as a table

o=obj_new('cws_stats')
o->set_product,'ctp'
o->set_date,2008,6,13,12,00
o->make_tables
obj_destroy, o

cloud top pressure statistics

Two algorithm scatter plot

o=obj_new('cws_stats')
o->set_product,'ctt'
o->set_date,2008,6,13,12,00
o->make_corSingle
obj_destroy, o

cloud top temperature scatter plots

Thumbnails of all scatter plots

o=obj_new('cws_stats')
o->set_product,'ctt'
o->set_date,2008,6,13,12,00
o->make_corThumb
obj_destroy, o

overview cloud top temperature correlation plots

Make ISCCP like plots

o=obj_new('cws_stats')
o->cod_ctp
obj_destroy, o

ISCCP like CTP COD histogram