Re: plot colored ellipsoid
- To: mathgroup at smc.vnet.net
- Subject: [mg110855] Re: plot colored ellipsoid
- From: "David Park" <djmpark at comcast.net>
- Date: Thu, 8 Jul 2010 20:33:16 -0400 (EDT)
This comes about because Ellipsoid is returned as a Graphic instead of as a graphics primitive, and because it builds in a color directive. It might be better if they left the color directive out and let the user specify it. With Presentations we can turn the Ellipsoid into a primitive and kill off the purple by using the DrawGraphics command. Needs["Presentations`Master`"] Needs["MultivariateStatistics`"] We define a new draw command to draw Ellipsoids. DrawEllipsoid[Ellipsoid[args__]] := DrawGraphics[Graphics[{Ellipsoid[args]}]] Then it is easy to draw as many Ellipsoids as we want, each in their own style. Draw2D[ {Black, DrawEllipsoid[ Ellipsoid[{1.4, 1.4}, {1.4, 5.7}, {{-0.7, 0.6}, {-0.6, -0.7}}]], Red, DrawEllipsoid[ Ellipsoid[{1.3, 2.8}, {1.4, -5.7}, 2 {{0.7, -0.6}, {6.6, -0.7}}]]}, ImageSize -> 250] David Park djmpark at comcast.net http://home.comcast.net/~djmpark/ From: J. Batista [mailto:jbatista800 at gmail.com] You are correct, I was not able to change the colors either. I also tried plotting several ellipsoids together, but they all had the same standard color. This may be an indication that the Multivariate Statistics package may not support all graphic primitives. Mathematica version 6 produced the same results. Regards, J. Batista On Wed, Jul 7, 2010 at 7:41 AM, Jordi <j.schaber at web.de> wrote: > Hi, > > For some reason I cannot color my ellipsoid. > I use, e.g., > Graphics[{Black, > Ellipsoid[{1.4, 1.4}, {1.4, 5.7}, {{-0.7, 0.6}, {-0.6, -0.7}}]}] > > Other graphics options like 'Thick' or 'Dashed' pose no problem, but it > always comes with the standard color. > > any idea? > > Thanks > >