close all
clear all

addpath(genpath('../../MatlabProcessing')); % Add directory and sub-directories to path.


results_table = readtable('../MonoChromaticRuns/latest_batch_results/batch_runs.log');
table_size = size(results_table);

for i = 1:table_size(1)
  mkdir(['../MonoChromaticRuns/latest_batch_results/' results_table.pblogFilename{i} '/../matlab']);
  copyfile(['../MonoChromaticRuns/latest_batch_results/' results_table.pblogFilename{i} '/*.csv'], ...
          ['../MonoChromaticRuns/latest_batch_results/' results_table.pblogFilename{i} '/../matlab/.']);
  files = dir(['../MonoChromaticRuns/latest_batch_results/' results_table.pblogFilename{i} '/../matlab/*.csv'])
  for j = 1:length(files);
      files(j).folder
      files(j).name(1:end-4)
    ConvertDataToMatlab([files(j).folder '\'],files(j).name(1:end-4));
    MakeQuickViewPlots([files(j).folder '\'],files(j).name(1:end-4));
  end

  delete(['../MonoChromaticRuns/latest_batch_results/' results_table.pblogFilename{i} '/../matlab/*.csv']);

end
A = [0.25, 0.25, 0.25, 0.25, 0.25, .25,  0.5, 0.5, 0.5,  0.5,  0.5,  0.5,   1.0, 1.0, 1.0, 1.0, 1.0, 1.0,     1.5, 1.5, 1.5, 1.5,  1.5,  1.5,   2.0, 2.0, 2.0,  2.0,  2.0,  2.0,   2.5, 2.5, 2.5,  2.5,  2.5,  2.5];
T = [4.0, 6.0, 8.0, 10.0, 12.0, 14.0,   4.0, 6.0, 8.0, 10.0, 12.0, 14.0,   4.0, 6.0, 8.0, 10.0, 12.0, 14.0,  4.0, 6.0, 8.0, 10.0, 12.0, 14.0,   4.0, 6.0, 8.0, 10.0, 12.0, 14.0,   4.0, 6.0, 8.0, 10.0, 12.0, 14.0];

