Hi,(adsbygoogle = window.adsbygoogle || []).push({});

I have a matrix for instance as follow:

A=[0.087 11.43 17.14 22.86 28.57 34.29 40.00 45.72 51.43 57.15

0.174 5.671 8.506 11.34 14.17 17.01 19.84 22.68 25.52 28.35

0.261 3.732 5.598 7.464 9.330 11.19 13.06 14.92 16.79 18.66

0.349 2.747 4.121 5.494 6.868 8.242 9.616 10.98 12.36 13.73

0.436 2.144 3.216 4.289 5.361 6.433 7.505 8.578 9.650 10.72

0.523 1.732 2.598 3.464 4.330 5.196 6.062 6.928 7.794 8.660];

I want to have all of this plot:

hold all

plot(A(:,1),A(:,2))

plot(A(:,1),A(:,3))

plot(A(:,1),A(:,4))

plot(A(:,1),A(:,5))

plot(A(:,1),A(:,6))

plot(A(:,1),A(:,7))

plot(A(:,1),A(:,8))

plot(A(:,1),A(:,9))

plot(A(:,1),A(:,10))

Can I have all of those plot just by using one plot command in a loop? If this is the case how can I do?

Thank you.

Best Regards,

Mathias

**Physics Forums - The Fusion of Science and Community**

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Plot in a loop in matlab

Loading...

Similar Threads - Plot loop matlab | Date |
---|---|

Plotting results from for loop | Apr 26, 2014 |

Use DO loop in Plot order at mathematica 8 | Oct 19, 2013 |

MATLAB-saving data after loops for surf plot | Apr 14, 2012 |

How to plot multiple iterations of a while loop on one plot? [MATLAB] | Oct 6, 2011 |

Matlab: Plotting loops, arrays | Jul 1, 2009 |

**Physics Forums - The Fusion of Science and Community**