The file documents the scripts used to compute the wind
intercomparison statistics and figures in the paper.

The *Bulk* scripts compute statistics for each individual centre, 
independently.

The *Match* scripts determine co-located AMVs from all the
data producers, collectively. Statistics and figures are generated.

The following 2 bulk AMV statistics scripts are MATLAB functions:

Bulk AMV Statistics
---------------
Winds_Bulk_QINF.m 
Winds_Bulk_CQI.m

function success = Winds_Bulk_QINF(exp,inpd,qitype,qival)
function success = Winds_Bulk_CQI(exp,inpd,qitype,qival)

Where:
exp - experiment number 1 or 2
inpd - full path to directory of containing AMV text files
qitype - QI type: with forecast (18) or without (17)
qival - QI threshold (either 50 or 80)

An example call to the Winds_Bulk_QINF_EUM script for
Experiment: 2
Text files location: /data/rdworak/Intercomp/exp22/
QI with no forecast: 17
QI threshold: 80

Winds_Bulk_QINF_EUM(2,'/data/rdworak/Intercomp/exp22/',17,50)

The following 2 collocated AMV statistics scripts are MATLAB functions:
Collocated AMV Statistics
---------------
Winds_Match_QINF_EUM.m
Winds_Match_CQI_EUM.m

function success = Winds_Match_QINF_EUM(exp,inpd,qitype,dist,qi)
function success = Winds_Match_CQI_EUM(exp,inpd,qitype,dist,qi)

Where:
exp - experiment number 1 or 2
inpd - full path to directory of containing AMV text files
qitype - QI type: with forecast (18) or without (17)
dist - distance threshold in KM
qi - QI threshold (either 50 or 80)

RAOB comparisons
----------------
The following two MATLAB scripts, compare all AMVs to RAOBs. There are no
input arguments to the scripts, however, the full_path/inputfile contains
the input AMV filename to compute the statistics.
raobdiff_exp21.m
raobdiff_exp22.m

The bash script runit_coll calls doit1_coll and doit2_coll, which in turn
call the raobdiff MATLAB scripts to process both experiments by QINF and CQI

Best Fit analysis and Grid comparison
-------------------------------------
The following scripts perform the Best Fit analysis and the comparison
of the AMVs to the ECMWF reanalysis grids:
runit_exp21: The bash driver script to run Python script test_amv.py for
             experiment 1.
runit_exp22: The bash driver script to run Python script test_amv.py for
             experiment 2.

=================

Note: The bash scripts should run on any version of Linux. The Matlab 
scripts were run using version 2014b and the Python scripts running Python
version 2.6.6 and shellb3 version 2014-q1. There is no guarantee that the results 
will be the same running different version.
