From 52e96c14143f74f36180d4219d2bf3a8172dfb8b Mon Sep 17 00:00:00 2001 From: Olivier Sauter <Olivier.Sauter@epfl.ch> Date: Wed, 10 Jun 2020 23:09:23 +0200 Subject: [PATCH] correct source to be string and fix list of tcv_get_ids_xxxx list --- matlab/TCV_IMAS/tcv_available_ids.m | 14 ++++++++++---- matlab/TCV_IMAS/tcv_get_ids_summary.m | 4 ++-- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/matlab/TCV_IMAS/tcv_available_ids.m b/matlab/TCV_IMAS/tcv_available_ids.m index a98cf4f1..004e29ac 100644 --- a/matlab/TCV_IMAS/tcv_available_ids.m +++ b/matlab/TCV_IMAS/tcv_available_ids.m @@ -1,6 +1,12 @@ -function list = tcv_available_ids() +function list = tcv_available_ids +% +% functions to get ids structure xxx from tcv data are called: tcv_get_ids_xxx.m +% return all these functions assuming they are in the same folder +% -list = {'equilibrium', 'magnetics', 'tf', 'pf_active','wall','core_profiles','ec_launchers','nbi','pf_passive', ... - 'thomson_scattering', 'summary'}; +[a1,a2]=fileparts(mfilename('fullpath')); +bb=dir([a1 '/tcv_get_ids_*.m']); +for i=1:numel(bb) + list{i} = bb(i).name(13:end-2); +end -end \ No newline at end of file diff --git a/matlab/TCV_IMAS/tcv_get_ids_summary.m b/matlab/TCV_IMAS/tcv_get_ids_summary.m index 0f543994..15a49607 100644 --- a/matlab/TCV_IMAS/tcv_get_ids_summary.m +++ b/matlab/TCV_IMAS/tcv_get_ids_summary.m @@ -233,8 +233,8 @@ params_eff.data_request = 'vloop'; global_quantities.v_loop = gdat(params_summary.shot,params_eff); tensvloop=-1e3; global_quantities.v_loop.data = interpos(global_quantities.v_loop.t,-global_quantities.v_loop.data,tensvloop); -global_quantities_desc.v_loop = [params_eff.data_request ' ; -1* interpos of ' global_quantities.v_loop.data_fullpath ... - ' with tens=' num2str(tensvloop)]; +global_quantities_desc.v_loop = [params_eff.data_request ' ; -1* interpos of ' global_quantities.v_loop.data_fullpath{1} ... + ' ' global_quantities.v_loop.data_fullpath{end} ' with tens=' num2str(tensvloop)]; params_eff.data_request = 'volume'; global_quantities.volume = gdat(params_summary.shot,params_eff); global_quantities_desc.volume = [params_eff.data_request ' ; ' global_quantities.volume.data_fullpath]; -- GitLab