Skip to content
Back to formatted view

Raw Message

Message-ID: <CA+vqiLFysokhwAP=EF7vvU2o2ZawXb3gWr+SVXkj7f4ZM_jmUg@mail.gmail.com>
Date: 2013-02-04T13:11:57Z
From: Ista Zahn
Subject: ggplot and colors
In-Reply-To: <CAF=-T0g3ZPf9fnN_2irgfGaoyhGxnARGzZAQucC_iE1jZmZViA@mail.gmail.com>

Hi,

fill is not the same as color. You need

scale_color_manual(values=c("black",
"black" , "black", "black", "black", "black", "black", "black", "black",
"black", "black", "black" ))

although it is not clear why you are using aesthetic mapping to set
everything to black...

Best,
Ista

On Mon, Feb 4, 2013 at 6:17 AM, Adel ESSAFI <adelessafi at gmail.com> wrote:
> Hello,
> I have a problem with ggplot and colors
>
> I used this function to draw somes lines and I want them to be all black
> (just to test)
> however, I dont get any black line in the figure.
>
> Do you have any experience with ggplot and manual colors??
>
>
>
> ggplot(cmax, aes(cmax[,3], cmax[,6],colour=interaction(cmax[,1],cmax[,2])))
> + geom_line() +  geom_point() +  scale_fill_manual(values=c("black",
> "black" , "black", "black", "black", "black", "black", "black", "black",
> "black", "black", "black" ))
>
>
> best regards
>
>
>
>
>
> --
> PhD candidate in Computer Science
> Address
> 3 avenue lamine, cit? ezzahra, Sousse 4000
> Tunisia
> tel: +216 97 246 706 (+33640302046 jusqu'au 15/6)
> fax: +216 71 391 166
>
> ______________________________________________
> R-help at r-project.org mailing list
> 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.
>