From: Seshadri on
I have observed temperatures and simulated temperatures for a year. I want to make a box plot with x-axis being months (Jan-Dec). At each month on the x-axis, I want to show the box plot of both observed and simulated temperatures. Is there some matlab command that I can directly use to do this? I know of the boxplot command. Not sure how to group obs and simulated values so that they plot out in lets say different colors.
From: us on
"Seshadri " <getjunke(a)gmail.com> wrote in message <i3snee$c7v$1(a)fred.mathworks.com>...
> I have observed temperatures and simulated temperatures for a year. I want to make a box plot with x-axis being months (Jan-Dec). At each month on the x-axis, I want to show the box plot of both observed and simulated temperatures. Is there some matlab command that I can directly use to do this? I know of the boxplot command. Not sure how to group obs and simulated values so that they plot out in lets say different colors.

show CSSMers a small example of your input/desired result using a snippet of ML code...

us
From: Tom Lane on
> I have observed temperatures and simulated temperatures for a year. I want
> to make a box plot with x-axis being months (Jan-Dec). At each month on
> the x-axis, I want to show the box plot of both observed and simulated
> temperatures. Is there some matlab command that I can directly use to do
> this? I know of the boxplot command. Not sure how to group obs and
> simulated values so that they plot out in lets say different colors.


Type "help boxplot". If you have a relative up-to-date version then you will
see a 'colorgroup' option listed. That should do what you want.

-- Tom

From: Seshadri on
h1 = boxplot(bp,'symbol','','widths',0.4);

where dimension of bp is 24x30. Now the 24 values are 12 for observed and 12 for simulated monthly (Jan-Dec) values. So I simply need on the xaxis J-D (12 ticks) and at each tick I display the boxplot of both observed and simulated values. I am not clear how to use the colorgroup option to color differently obs and sim values.

"us " <us(a)neurol.unizh.ch> wrote in message <i3srqj$e87$1(a)fred.mathworks.com>...
> "Seshadri " <getjunke(a)gmail.com> wrote in message <i3snee$c7v$1(a)fred.mathworks.com>...
> > I have observed temperatures and simulated temperatures for a year. I want to make a box plot with x-axis being months (Jan-Dec). At each month on the x-axis, I want to show the box plot of both observed and simulated temperatures. Is there some matlab command that I can directly use to do this? I know of the boxplot command. Not sure how to group obs and simulated values so that they plot out in lets say different colors.
>
> show CSSMers a small example of your input/desired result using a snippet of ML code...
>
> us
From: Seshadri on
Thanks Tom,

I tried to look up how to use the colorgroup option, and did not find good documentation. This might solve the problem, though I have not figured it out yet.
S
"Tom Lane" <tlane(a)mathworks.nospam.com> wrote in message <i3ub7r$c3a$1(a)fred.mathworks.com>...
> > I have observed temperatures and simulated temperatures for a year. I want
> > to make a box plot with x-axis being months (Jan-Dec). At each month on
> > the x-axis, I want to show the box plot of both observed and simulated
> > temperatures. Is there some matlab command that I can directly use to do
> > this? I know of the boxplot command. Not sure how to group obs and
> > simulated values so that they plot out in lets say different colors.
>
>
> Type "help boxplot". If you have a relative up-to-date version then you will
> see a 'colorgroup' option listed. That should do what you want.
>
> -- Tom