From 22dc43ff4cae0d085d314e24e8c27292e94b6517 Mon Sep 17 00:00:00 2001 From: Olivier Sauter <olivier.sauter@epfl.ch> Date: Mon, 3 Apr 2023 16:32:33 +0200 Subject: [PATCH] set sys in cxrs defaults from input sources --- matlab/TCV/gdat_tcv.m | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/matlab/TCV/gdat_tcv.m b/matlab/TCV/gdat_tcv.m index c8a7ddbd..c9b6bef8 100644 --- a/matlab/TCV/gdat_tcv.m +++ b/matlab/TCV/gdat_tcv.m @@ -947,10 +947,6 @@ elseif strcmp(mapping_for_tcv.method,'switchcase') sub_nodes = {'Ti','vTor','vPol','nC','Zeff'}; % first node is also copied into data, choose "default' one sub_nodes_out = lower({'Ti','vTor','vPol','ni','Zeff'}); % sub_nodes_units = {'eV','m/s','m/s','m^{-3}',''}; % first node is also copied into data, choose "default' one - % use A. Karpushov routine to get profiles and then copy the data or the fitted profiles - aa=CXRS_get_profiles; cxrs_params = aa.param; - gdat_data.cxrs_params.defaults = cxrs_params; - cxrs_params.k_plot=0; cxrs_params.k_debug=0; % add params from gdat call params_eff = gdat_data.gdat_params; if isfield(params_eff,'cxrs_plot') && params_eff.cxrs_plot>0 @@ -964,6 +960,11 @@ elseif strcmp(mapping_for_tcv.method,'switchcase') source = [1 2 3]; end gdat_data.gdat_params.source = source; + % use A. Karpushov routine to get profiles and then copy the data or the fitted profiles + aa=CXRS_get_profiles([],gdat_data.gdat_params.source); cxrs_params = aa.param; % get default params with sys defined + gdat_data.cxrs_params.defaults = cxrs_params; + cxrs_params.k_plot=0; cxrs_params.k_debug=0; + if isfield(params_eff,'cxrs_time_interval') && ~isempty(params_eff.cxrs_time_interval) && length(params_eff.cxrs_time_interval)>=2 cxrs_time_interval = params_eff.cxrs_time_interval; if ~isfield(params_eff,'cxrs_plot') -- GitLab