default_output.pl
author A.M. Thurnherr <athurnherr@yahoo.com>
Thu, 16 Mar 2017 11:53:27 -0400
changeset 48 d9309804b6cf
parent 47 2ccb81b7cea5
child 54 828e5466391b
permissions -rw-r--r--
V1.3 release
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
47
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     1
#======================================================================
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     2
#                    D E F A U L T _ O U T P U T . P L 
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     3
#                    doc: Wed Jun  1 19:21:19 2016
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     4
#                    dlm: Wed Jun  1 19:26:01 2016
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     5
#                    (c) 2016 A.M. Thurnherr
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     6
#                    uE-Info: 106 1 NIL 0 0 72 0 2 4 NIL ofnI
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     7
#======================================================================
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     8
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
     9
# NOTES:
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    10
#  - as this file is executed after ProcessingParams, only undefined
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    11
#	 variables are set
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    12
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    13
# HISTORY:
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    14
#	Jun  1, 2016: - created from [default_paths.pl]
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    15
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    16
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    17
# Processing log (diagnostic messages) output
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    18
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    19
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    20
$out_log = "$log_dir/$out_basename.log"
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    21
	unless defined($out_log);
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    22
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    23
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    24
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    25
# Vertical-velocity profile output and plots:
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    26
#
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    27
# Data:
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    28
#	*.wprof				vertical velocity profiles
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    29
#
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    30
# Plots:
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    31
# 	*_wprof.ps			vertical velocity profiles (main output plot)
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    32
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    33
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    34
unless (@out_profile) {
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    35
	push(@out_profile,"$data_dir/$out_basename.wprof");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    36
	push(@out_profile,"plot_wprof($plot_dir/${out_basename}_wprof.ps)")
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    37
		if ($plotting_level > 0);
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    38
}
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    39
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    40
#--------------------------------------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    41
# Vertical-velocity sample data output and plots:
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    42
#
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    43
# Data (in $data_dir):
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    44
#	*.wsamp							w sample data
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    45
#	residuals/<prof>/<ens>.rprof	OPTIONAL: per-ensemble residuals
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    46
#						
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    47
# Plots (in $plot_dir):
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    48
#	*_wsamp.ps						1: vertical velocity time-depth plot
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    49
#	*_residuals.ps					1: residual vertical velocity time-depth plot
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    50
#	*_residual_profs.ps				1: residuals binned in depth
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    51
#	*_backscatter.ps				1: volume scattering coefficient time-depth plot
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    52
#	*_attitude_res.ps				2: residuals binned wrt. pitch/roll
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    53
#	*_residuals12.ps				2: beampair <1,2> residual vertical velocity time-depth plot
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    54
#	*_residuals34.ps				2: beampair <3,4> residual vertical velocity time-depth plot
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    55
#	*_attitude_res.ps				2: residuals binned wrt. package attitude
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    56
#	*_acceleration_res.ps			2: residuals binned wrt. package acceleration derivative
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    57
#	*_correlation.ps				3: correlation time-depth plot
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    58
#--------------------------------------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    59
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    60
unless (@out_wsamp) {
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    61
	push(@out_wsamp,"$data_dir/$out_basename.wsamp");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    62
	#push(@out_wsamp,sprintf('dump_residual_profiles(%s/residuals/%03d)',$data_dir,$PROF));
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    63
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    64
	if ($plotting_level > 0) {
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    65
		push(@out_wsamp,"plot_wsamp($plot_dir/${out_basename}_wsamp.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    66
		push(@out_wsamp,"plot_residuals($plot_dir/${out_basename}_residuals.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    67
		push(@out_wsamp,"plot_residual_profs($plot_dir/${out_basename}_residual_profs.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    68
		push(@out_wsamp,"plot_backscatter($plot_dir/${out_basename}_backscatter.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    69
		if ($plotting_level > 1) {
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    70
			push(@out_wsamp,"plot_residuals12($plot_dir/${out_basename}_residuals12.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    71
			push(@out_wsamp,"plot_residuals34($plot_dir/${out_basename}_residuals34.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    72
			push(@out_wsamp,"plot_attitude_residuals($plot_dir/${out_basename}_attitude_res.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    73
			push(@out_wsamp,"plot_acceleration_residuals($plot_dir/${out_basename}_acceleration_res.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    74
			if ($plotting_level > 2) {
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    75
				push(@out_wsamp,"plot_correlation($plot_dir/${out_basename}_correlation.ps)");
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    76
			}
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    77
		}
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    78
	}
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    79
}
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    80
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    81
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    82
# Time-series output
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    83
#
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    84
#	*.tis			combined CTD/LADCP time-series data, including 
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    85
#					package- and LADCP reference layer w
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    86
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    87
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    88
push(@out_timeseries,"$data_dir/$out_basename.tis")
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    89
	unless (@out_timeseries);
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    90
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    91
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    92
# Per-bin vertical-velocity residuals (plot only)
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    93
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    94
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    95
push(@out_BR,"plot_mean_residuals($plot_dir/${out_basename}_bin_residuals.ps)")
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    96
	unless (@out_BR);
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    97
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    98
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
    99
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   100
# Time-lagging correlation statistics (plot only)
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   101
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   102
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   103
unless (@out_TL) {
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   104
	push(@out_TL,"plot_time_lags($plot_dir/${out_basename}_time_lags.ps)")
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   105
		if ($plotting_level > 0);
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   106
}
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   107
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   108
#----------------------------------------------------------------------
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   109
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   110
1;	# return true
2ccb81b7cea5 version found on whoosher after repair
A.M. Thurnherr <athurnherr@yahoo.com>
parents:
diff changeset
   111