[R] Adding average into a matplot?

Mike Prager mike.prager at noaa.gov
Thu Apr 10 19:20:45 CEST 2008

-Halcyon- <Cyonora at gmail.com> wrote:

> I have a matrix which is filled with simulation results for several years.
> Example of an output (7 years, 4 simulations):
> My matplot gives me 4 lines, but I would like to add a line with the
> averages of each year for all simulations. Can anyone help me with this?

Take a look at help pages of the following functions:  mean,
apply, abline.

Mike Prager, NOAA, Beaufort, NC
* Opinions expressed are personal and not represented otherwise.
* Any use of tradenames does not constitute a NOAA endorsement.

More information about the R-help mailing list