From 86f03542820ae9cb4fa7cdbce34320a51caf23c0 Mon Sep 17 00:00:00 2001 From: Olivier Sauter <olivier.sauter@epfl.ch> Date: Wed, 30 Sep 2015 12:31:13 +0000 Subject: [PATCH] fix when cxrs empty git-svn-id: https://spcsvn.epfl.ch/repos/TCV/gdat/trunk@5078 d63d8f72-b253-0410-a779-e742ad2e26cf --- crpptbx/TCV/gdat_tcv.m | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/crpptbx/TCV/gdat_tcv.m b/crpptbx/TCV/gdat_tcv.m index 62815d56..50b6fcaf 100644 --- a/crpptbx/TCV/gdat_tcv.m +++ b/crpptbx/TCV/gdat_tcv.m @@ -586,6 +586,10 @@ elseif strcmp(mapping_for_tcv.method,'switchcase') cxrs_params.k_plot = cxrs_plot; cxrs_profiles = CXRS_get_profiles(shot,[1 2 3],time_interval,cxrs_params); inb_times = length(cxrs_profiles.Times); + if isempty(cxrs_profiles.Times) || ~isfield(cxrs_profiles,'proffit') + if (gdat_params.nverbose>=1); warning(['problems loading data with CXRS_get_profiles for data_request= ' data_request_eff]); end + return + end inb_channels =120; % need to change if gets bigger!!! but easier to prefill with NaNs and use the "use" part for i=1:length(sub_nodes) sub_eff = sub_nodes{i}; -- GitLab