Can i connect a matlab code to the app enviroment?

11 ビュー (過去 30 日間)
andreas christou
andreas christou 2020 年 1 月 31 日
回答済み: Ganesh Regoti 2020 年 2 月 4 日
Can i for example run my code from app designer or take as an input the variables from matlab file ?
  2 件のコメント
Mohammad Sami
Mohammad Sami 2020 年 1 月 31 日
yes and yes. what are you trying to do ?
andreas christou
andreas christou 2020 年 1 月 31 日
I have the follwing main matlab code
load('Load_Profiles')
ts=1;
num_iter=2 ;
% SV_vector=zeros(numb_SV+3,num_iter);
PQtotal=struct('P',zeros(21,num_iter),'Q',zeros(21,num_iter));
PQtotal_LV=struct('P',zeros(20,num_iter),'Q',zeros(20,num_iter));
for i=1:num_iter
cd SE-MV
[SV_vector(:,i), line_loading(i,:), PQtotal]=SE_MV(Meas,ts,PQtotal,i);
cd ..
Meas_Bus=Meas(14).signals.values;
Voltage=SV_vector(979:981,i);
[Meas_LV]=LV_profile(Meas_Bus);
load('Load_profile_LV');
cd SE-LV
[SV_vector_LV(:,i)]=SE_LV(Meas_LV,ts,Voltage);
%
cd ..
%
%
ts=ts+1;
i
end
and i want to put as an input the num_iter

サインインしてコメントする。

回答 (1 件)

Ganesh Regoti
Ganesh Regoti 2020 年 2 月 4 日
Hi,
As per my understanding, you want to load data from mat file to appdesigner. load function must work for you
var=load('example.mat');
If you want to load data from any workspace into appdesigner code, then evalin function works fine.
v = evalin('base', 'var');
Here are the links you can refer to
Hope this helps!

カテゴリ

Help Center および File ExchangeDevelop Apps Using App Designer についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by