MATLAB: How to plot multiple data sets on the same graph multiple variableplot The following coding is only plotting the first two variables on the plot. plot(years,run_rate,'r-s',years,CL,'g-',years,UCL,'g-',years,LCL,'g-'); Best Answer Use hold on command between. For instance:plot(years,run_rate,'r-s');hold on;plot(years,CL,'g-');hold on;plot(years,UCL,'g-');hold on;plot(years,LCL,'g-') Related SolutionsMATLAB: Plotting data throughout a 24 hour period I would suggest the following:hour = datevec(:,4);minute = datevec(:,5);hour_decimal = hour+minute/60;plot(hour_decimal,data)Does this what you want it to do? MATLAB: Hi, I have a question about displaying the line limit for p-chart. The line always displayed in y=0. Probabilities are between 0 and 1. When you plot a value between 0 and 1 on a plot that goes up to 450, the value is going to be squished near the y axes. Related QuestionIs this code giving me an errorHow to combine these two MATLAB codes? (MATLAB)Creating a function to plot multiple column of a variable in workspaceHow Create Pentad averageLoop multiple plots single figure 3D matrix
Best Answer