Re: how to display colors for group of samples while plotting a given signal

• To: mathgroup at smc.vnet.net
• Subject: [mg51401] Re: how to display colors for group of samples while plotting a given signal
• From: "Peter Pein" <petsie at arcor.de>
• Date: Sat, 16 Oct 2004 04:20:33 -0400 (EDT)
• References: <cknsjr\$5fi\$1@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

Kumar:

pl = ListPlot[Table[Sin[x/123], {x, 3000}]];

(*You can assume pl is your already generated (black & white) plot.*)

plcol = pl /. p:Point[{x_, _}] :> Sequence[p, If[Mod[x, 300, 1] < 100,
RGBColor[1, 0, 0], RGBColor[0, 0, 1]]];

Show[plcol];

Have success,
Peter
--
Peter Pein, Berlin
to write to me, start the subject with [

"kumar" <kriana at rediffmail.com> schrieb im Newsbeitrag
news:cknsjr\$5fi\$1 at smc.vnet.net...
> sir,
>       i am facing problem on displaying colors for separate group of
> samples for a given signal.HINT the signal length is 3000.in that
> sample for 100 sample each i want to display one color and for another
> sample of 200 each i want to display another color.if anyone guide to
> solve this problem .pls reply .urgent.
>                        Thanking you
> regards
> kumar
>

• Prev by Date: LegendreP (Symbolic) is different in Mathematica5 than previous versions (M4, M3 ..)
• Next by Date: Re: Re: Very basic question: Zoom into a 2-D plot with the mouse
• Previous by thread: how to display colors for group of samples while plotting a given signal
• Next by thread: Need help with HISTOGRAM plotting