Deborah.RebekahMiriam.PXvsBSPlotterRebekahMiriam
Deborah.RebekahMiriam.PXvsBSPlotterRebekahMiriam.build_flat_plot_dict — Methodbuild_flat_plot_dict(
key::Symbol,
orig_tag::Symbol,
pred_tag1::Symbol,
pred_tag2::Symbol,
keyword::String,
new_dict::Dict{Tuple{Symbol, Symbol, Symbol, String}, Array{Float64,2}}
) -> Dict{String, Array{Float64,2}}Construct a flattened dictionary of average and error matrices for plotting, given a specific keyword and observable key.
This utility reformats selected entries from a 4-key dictionary new_dict—keyed by (observable, kind, tag, keyword)—into a flat Dict{String, Array} that mimics the naming convention used in Deborah.Rebekah.PXvsBSPlotter (e.g., "kurt:P_P2:avg").
It includes data from two prediction methods (pred_tag1, pred_tag2) as well as the original reference tag (orig_tag) for the specified observable key and criterion keyword.
Key naming convention in the returned dictionary:
- Predictions:
"$key:Y_<pred_tag>:avg"and"$key:Y_<pred_tag>:err" - Original:
"$key:Y:<orig_tag>:avg"and"$key:Y:<orig_tag>:err"(Note the underscore for predictions vs colon for the original tag, matchingDeborah.Rebekah.PXvsBSPlotterusage.)
Arguments
key: Observable symbol (e.g.,:kurt).orig_tag: Original/reference tag to include (previously hard-coded as:RWBS).pred_tag1: First prediction tag to include (e.g.,:RWP1).pred_tag2: Second prediction tag to include (e.g.,:RWP2).keyword: Selector used innew_dict(e.g.,"susp","skew","kurt"as interpolation criterion; or a $\kappa$ token like"13580"in measurement flows).new_dict: Source dictionary keyed by(key, kind, tag, keyword)and valued withlabels$\times$trainsmatrices.
Returns
- A flattened dictionary with keys like
"kurt:Y_P2:avg"or"kurt:Y:RWBS:err"mapped to matrices, suitable for direct use in plotting.
Deborah.RebekahMiriam.PXvsBSPlotterRebekahMiriam.plot_PX_BS_vs_labels — Methodplot_PX_BS_vs_labels(
key::String,
suffix_orig::String,
suffix1::String,
suffix2::String,
train_pct::Int,
new_dict::Dict{String, Array{Float64,2}},
labels_int::Vector{Int},
trains_ext_int::Vector{Int},
keyword::String,
overall_name::String,
figs_dir::String;
key_tex::String = "",
save_file::Bool = false
) -> NothingPlot P1, P2, and original values versus labeled set percentage for a fixed training set size, in a Deborah.Miriam analysis.
This function is specific to the Deborah.RebekahMiriam. It visualizes the behavior of a given observable (key) across varying label set sizes (labels_int), while fixing the training set percentage to train_pct.
The plotted values are extracted from new_dict, containing average and error arrays for:
- baseline method (
suffix_orig) - first estimation method (
suffix1) - second estimation method (
suffix2)
Each curve is plotted with its own marker style and color, and slightly shifted on the $x$-axis to improve readability. The $y$-axis reflects the observable evaluated at a specific interpolation point $\kappa_t$ determined by keyword.
Arguments
key::String: Name of the observable to be plotted (e.g.,"skew","kurt").suffix_orig::String: Suffix used in the key for baseline values (e.g.,"RWBS").suffix1::String: Suffix for the first interpolation method (e.g.,"RWP1").suffix2::String: Suffix for the second interpolation method (e.g.,"RWP2").train_pct::Int: The training set percentage (used to select the column index from the 2D arrays).new_dict::Dict{String, Array{Float64,2}}: Dictionary containing all relevant observable averages and error bars.labels_int::Vector{Int}: Label set percentages to use for the $x$-axis.trains_ext_int::Vector{Int}: Training set percentages, used to resolve the index fortrain_pct.keyword::String: The origin cumulant that was used to determine the interpolation point $\kappa_t$. For example,"kurt"means that $\kappa_t$ was selected based on kurtosis behavior, and the observable inkeywas evaluated at that point.overall_name::String: Suffix used for output filenames.figs_dir::String: Output directory to save the figure.
Keyword Arguments
key_tex::String = "": Optional $\LaTeX$ string used as $y$-axis label.save_file::Bool = false: Iftrue, the figure is saved as a PDF and cropped usingpdfcrop(if available).
Side Effects
- Displays a
PyPlot.jlfigure comparing three estimation methods at the specifiedtrain_pct. - If
save_file=true, saves a PDF namedplot_<key>_<keyword>_<overall_name>_TRP_<train_pct>.pdfintofigs_dir.
Deborah.RebekahMiriam.PXvsBSPlotterRebekahMiriam.plot_PX_BS_vs_labels_for_measurements — Methodplot_PX_BS_vs_labels_for_measurements(
key::String,
suffix_orig::String,
suffix1::String,
suffix2::String,
train_pct::Int,
new_dict::Dict{String, Array{Float64,2}},
labels_int::Vector{Int},
trains_ext_int::Vector{Int},
keyword::String,
overall_name::String,
figs_dir::String;
key_tex::String = "",
save_file::Bool = false
) -> NothingPlot P1, P2, and original values versus labeled-set percentage at a fixed training-set size, for the single-ensemble-measurement-based workflow.
This variant mirrors plot_PX_BS_vs_labels but interprets keyword as a kappa token string (e.g., "13580"). The plot title shows $\kappa =$ 0.<keyword> (e.g., $\kappa = 0.13580$), indicating that all series are evaluated at that specific measurement point rather than an interpolation-derived $\kappa_t$.
The function visualizes a selected observable key across labels_int, while fixing the training-set percentage to train_pct. Three curves are drawn:
- baseline/original (
suffix_orig), - first estimation method (
suffix1), - second estimation method (
suffix2).
Values are fetched from new_dict, which stores average and error matrices indexed by (label_index, train_index) behind flattened keys:
"$key:Y_$suffix:avg"/"$key:Y_$suffix:err"for predictions,"$key:Y:$suffix_orig:avg"/"$key:Y:$suffix_orig:err"for the original.
The special case key == "Deborah" omits the "$key:" prefix to match legacy naming.
Arguments
key::String: Observable to plot (e.g.,"trM1","Q2").suffix_orig::String: Baseline/original tag suffix (e.g.,"Y_BS").suffix1::String: First method suffix (e.g.,"Y_P1").suffix2::String: Second method suffix (e.g.,"Y_P2").train_pct::Int: Training-set percentage; selects a column from the matrices.new_dict::Dict{String, Array{Float64,2}}: Flattened dictionary containing avg/err arrays.labels_int::Vector{Int}: Labeled-set percentages for the $x$-axis.trains_ext_int::Vector{Int}: Training-set percentages; used to resolvetrain_pct.keyword::String: $\kappa$ token for titling and output naming (e.g.,"13580").overall_name::String: Suffix used in the output filename.figs_dir::String: Directory to save the figure.
Keyword Arguments
key_tex::String = "": Optional $\LaTeX$ $y$-axis label for the observable.save_file::Bool = false: Iftrue, savesplot_<key>_<keyword>_<overall_name>_TRP_<train_pct>.pdfand crops withpdfcropif available.
Side Effects
- Displays a
PyPlot.jlfigure comparing three methods at the specifiedtrain_pct. - Optionally writes a PDF to disk when
save_file=true.
Notes
- Assumes measurement summaries indexed by discrete $\kappa$ tokens; ensure
new_dictwas built accordingly. - Curves are slightly offset along $x$ for readability; error bars are shown for each series.
Deborah.RebekahMiriam.PXvsBSPlotterRebekahMiriam.plot_PX_BS_vs_trains — Methodplot_PX_BS_vs_trains(
key::String,
suffix_orig::String,
suffix1::String,
suffix2::String,
label_pct::Int,
new_dict::Dict{String, Array{Float64,2}},
trains_ext_int::Vector{Int},
labels_int::Vector{Int},
keyword::String,
overall_name::String,
figs_dir::String;
key_tex::String = "",
save_file::Bool = false
) -> NothingPlot P1, P2, and original values versus training set percentage for a fixed label ratio, in a Deborah.Miriam analysis.
This function is specific to the Deborah.RebekahMiriam. It visualizes the behavior of a given observable (key) across varying training set sizes (trains_ext_int), while fixing the labeled set size to a specific value label_pct.
The plotted values are extracted from new_dict, containing average and error arrays for:
- baseline method (
suffix_orig) - first estimation method (
suffix1) - second estimation method (
suffix2)
Each curve is plotted with its own marker style and color, and slightly shifted on the $x$-axis to improve readability. The $y$-axis reflects the observable evaluated at a specific interpolation point $\kappa_t$ determined by keyword.
Arguments
key::String: Name of the observable to be plotted (e.g.,"skew","kurt").suffix_orig::String: Suffix used in the key for baseline values (e.g.,"RWBS").suffix1::String: Suffix for the first interpolation method (e.g.,"RWP1").suffix2::String: Suffix for the second interpolation method (e.g.,"RWP2").label_pct::Int: The label set percentage (used to select the row index from the 2D arrays).new_dict::Dict{String, Array{Float64,2}}: Dictionary containing all relevant observable averages and error bars.trains_ext_int::Vector{Int}: Training set percentages to use for the $x$-axis.labels_int::Vector{Int}: Labeled set percentages, used to resolve the index forlabel_pct.keyword::String: The origin cumulant that was used to determine the interpolation point $\kappa_t$. For example,"kurt"means that $\kappa_t$ was selected based on kurtosis behavior, and the observable inkeywas evaluated at that point.overall_name::String: Suffix used for output filenames.figs_dir::String: Output directory to save the figure.
Keyword Arguments
key_tex::String = "": Optional $\LaTeX$ string used as $y$-axis label.save_file::Bool = false: Iftrue, the figure is saved as a PDF and cropped usingpdfcrop(if available).
Side Effects
- Displays a
PyPlot.jlfigure comparing three estimation methods at the specifiedlabel_pct. - If
save_file=true, saves a PDF namedplot_<key>_<keyword>_<overall_name>_LBP_<label_pct>.pdfintofigs_dir.
Deborah.RebekahMiriam.PXvsBSPlotterRebekahMiriam.plot_PX_BS_vs_trains_for_measurements — Methodplot_PX_BS_vs_trains_for_measurements(
key::String,
suffix_orig::String,
suffix1::String,
suffix2::String,
label_pct::Int,
new_dict::Dict{String, Array{Float64,2}},
trains_ext_int::Vector{Int},
labels_int::Vector{Int},
keyword::String,
overall_name::String,
figs_dir::String;
key_tex::String = "",
save_file::Bool = false
) -> NothingPlot P1, P2, and original values versus training-set percentage at a fixed label ratio, for the single-ensemble-measurement-based workflow.
This variant mirrors plot_PX_BS_vs_trains but interprets keyword as a kappa token string (e.g., "13580"). The plot title explicitly shows $\kappa$ = 0.<keyword> (e.g., $\kappa =$ "0.13580"), indicating that all values are evaluated at that specific measurement point rather than an interpolation-derived $\kappa_t$.
The function visualizes a selected observable key across trains_ext_int, while holding the labeled-set size at label_pct. Three curves are shown:
- baseline/original (
suffix_orig), - first estimation method (
suffix1), - second estimation method (
suffix2).
Data are loaded from new_dict, which contains average and error matrices indexed by (label_index, train_index) using flattened keys such as:
"$key:Y_$suffix:avg"/"$key:Y_$suffix:err"for predictions,"$key:Y:$suffix_orig:avg"/"$key:Y:$suffix_orig:err"for the original.
The special case key == "Deborah" omits the "$key:" prefix to match Deborah.DeborahCore naming.
Arguments
key::String: Observable name to plot (e.g.,"trM1","Q2").suffix_orig::String: Baseline/original tag suffix (e.g.,"Y_BS").suffix1::String: First method suffix (e.g.,"Y_P1").suffix2::String: Second method suffix (e.g.,"Y_P2").label_pct::Int: Labeled-set percentage; selects the row from the matrices.new_dict::Dict{String, Array{Float64,2}}: Flattened dictionary with avg/err arrays.trains_ext_int::Vector{Int}: Training-set percentages for the $x$-axis.labels_int::Vector{Int}: Available labeled-set percentages; used to resolvelabel_pct.keyword::String: $\kappa$ token used for figure titling and output naming (e.g.,"13580").overall_name::String: Suffix used in the output filename.figs_dir::String: Directory for saving the figure.
Keyword Arguments
key_tex::String = "": Optional $\LaTeX$ $y$-axis label for the observable.save_file::Bool = false: Iftrue, savesplot_<key>_<keyword>_<overall_name>_LBP_<label_pct>.pdfand crops withpdfcropif available.
Side Effects
- Displays a
PyPlot.jlfigure comparing three methods at the specifiedlabel_pct. - Optionally writes the figure to disk when
save_file=true.
Notes
- This function assumes the measurement pipeline where results are indexed by discrete $\kappa$ values. Ensure that
new_dictwas built accordingly (e.g., viabuild_flat_plot_dict-style utilities). - Curves are horizontally offset slightly to improve readability; error bars are drawn for each series.