Saving data from for loops
이전 댓글 표시
Hello!
I am trying to plot all the Y-values from the for loop but it seems that I recieve a new Y-value from every itterations. I think that when plotting, I only plot ONE Y-value. not all of them. I believe saving all the Y-values into a array would make it possible to plot X,Y. How can I save the Y-values? Or is there any other way to plot my data?
clear all
close all
clc
Mmax=10.76; %Maximum mass
Mmin=10.32; %Minimum mass
Mdiff=0.44; %Mass difference
UptakeW=(Mdiff/Mmin); %In percentage
A=load('MMC#8-PURE_TGA-Heated_Samples_05102020.txt');
B=A(2735:4823,5);
X=0:0.1:50;
for i=0:0.01:Mdiff
Y=((i)./Mdiff)*100
end
plot(X,Y)
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Agriculture에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!