Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #4119
| From | Helen Read <readhpr@gmail.com> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: Multiple Styles |
| Date | 2011-08-01 03:39 +0000 |
| Organization | Steven M. Christensen and Associates, Inc and MathTensor, Inc. |
| Message-ID | <j15756$b4i$1@smc.vnet.net> (permalink) |
| References | <j13e5s$53p$1@smc.vnet.net> |
On 7/31/2011 7:26 AM, ace55555 wrote:
> I am trying to change both the thickness and color of four parametric curves using PlotStyle. However, I either get the thickness or the colors to work but not both. I tried two different lines of code at the end of ParametricPlot3D:
> ..,PlotStyle -> {{RGBColor[1,0,0]},{RGBColor[0,1,0]},{RGBColor[0,0,1]},{RGBColor[0,0,0]}},PlotStyle -> {Thickness[0.01]}
> ..,PlotStyle -> {{RGBColor[1,0,0]},{RGBColor[0,1,0]},{RGBColor[0,0,1]},{RGBColor[0,0,0]},{Thickness[0.01]}}
> It would be deeply appreciated if someone could help me on this matter. Thanks.
>
You can use Directive to specify multiple styles for each curve. For
example:
curves = Table[{r Cos[t], r Sin[t]}, {r, 1, 4}];
ParametricPlot[curves, {t, 0, 2 \[Pi]},
PlotStyle -> {Directive[Red, Thick], Directive[Blue, Dashed],
Directive[Green, Thick, Dashing[Large]],
Directive[Purple, Dotted]}]
With some of the plotting functions it will also work to give a list of
lists of Styles, like this:
ParametricPlot[curves, {t, 0, 2 \[Pi]},
PlotStyle -> {{Red, Thick}, {Blue, Thick}, {Green, Thick}, {Purple,
Thick,Dashed}}]
But sometimes Directive is required.
--
Helen Read
University of Vermont
Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Find similar | Unroll thread
Multiple Styles ace55555 <yeivanye@gmail.com> - 2011-07-31 11:26 +0000 Re: Multiple Styles Helen Read <readhpr@gmail.com> - 2011-08-01 03:39 +0000
csiph-web