I have a graph each time when I run according to the random number it will generate a new graph(TIME&VELOCITY) .Now I want to save each graphs time and velocity in order to upload and use it to other program .How should I do it?
2 次查看(过去 30 天)
显示 更早的评论
presently I am uploading this data to generate a graph
load('UDDS.mat');
% Get velocity and acceleration
vel = UDDS.Data;
time =UDDS.Time;
Simulteously ,I also use a random number to build a graph.If I generate more than one time I am getting a clumsy graph .As,it generate different graph for each run .first thing I should do is to see the graph clearly which is generated first ,second ,third so on.Next,I have to save the data of each graph in time and data .
plot(generated_cycle,'r')
xlabel('time steps(s)')
ylabel('velocity (km/h)')
%legend('original','stochastic')
I have attached my pic of clumsy graph below .
0 个评论
回答(1 个)
Aveek Podder
2018-2-20
Hi,
You can use 'gca' command to get the axis properties of a figure and access its children (line) properties like XData and YData. You can save this data for future use. For more information please have a look at the following links:
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Graph and Network Algorithms 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!