how can i combine 2 or more programm ?

조회 수: 2 (최근 30일)
Muhammad Dzulfikr Islami
Muhammad Dzulfikr Islami 2020년 11월 2일
댓글: Muhammad Dzulfikr Islami 2020년 11월 6일
i have make a programm that filter my data input from excel. As output i have a timetable.
Date Site Temperature
___________ ____ ___________
01-Mar-2017 1 5.9
01-Mar-2017 1 5.9
01-Mar-2017 1 5.7
01-Mar-2017 1 5.4
08-Mar-2017 1 6.3
08-Mar-2017 1 5.8
now i want to input this data on another model which i have created on another Programm. I want to input the variable and the Data set. so that, later i can do plot comparison between the simulation and the real data.
this is the model
r0=r0*exp(-(0.17*(watertemp-27))^2);
thirdly, i will visualize the data on another Program that i created nad make an Animation from it. using bubble
lat1 = [52.16069444 52.16005556 52.15916667 52.15816667 ];
lon1 = [10.54361111 10.54194444 10.54194444 10.54138889 ];
r0= [0.05 0.03 0.05 0.02];
gb = geobubble(lat1,lon1,r0);
gb.Basemap = 'streets';
the r0 should come from the Simulation.
geobubble

채택된 답변

Swetha Polemoni
Swetha Polemoni 2020년 11월 5일
Hi,
It is my understanding that you want to use data in one program which is generated in another progarm . You could use "function" in Matlab for this scenerio. You can write two functions each for your two different programs. You can use the output of one function in another function by making a function call. Consider the following code snippet for better understanding.
function out=myfunction
out=my_eqn(1,2); %% function call to my_eqn function to get a value
disp(out);
end
function a= my_eqn(x,y)
a=2*x^2+y+5;
end
Make sure that the Mfile name is same as your first function name.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by