... and if this is homework (it looks like it), you should know that
there is a no homework policy on this list.
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along
and sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )
On Mon, Feb 29, 2016 at 4:53 AM, Boris Steipe <boris.steipe at
utoronto.ca> wrote:> You need to pass a suitably constructed vector of color values to plot()
via the parameter "col". Read the section on "Color
Specification" for the par() function for details. Also read up on the
parameter "pch" for which symbol to use, a filled circle will usually
work well. See the help for points() for details. ifelse() will help you
construct the vector.
>
> B.
>
> On Feb 29, 2016, at 7:22 AM, Partha Sinha <pnsinha68 at gmail.com>
wrote:
>
>> I have the following fields in table:
>> height, weight, gender
>> i want to plot height and weight of gender(males and females). The data
>> points needs to be marked in two different colors.
>> Regards
>> parth
>>
>> [[alternative HTML version deleted]]
>>
>> ______________________________________________
>> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
>
> ______________________________________________
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.