[R] package 'corrplot'

Duncan Murdoch murdoch.duncan at gmail.com
Fri Feb 20 00:30:36 CET 2015


On 19/02/2015 6:13 PM, Antonello Preti wrote:> I'm using the package
'corrplot' for a figure to be used in an academic
> article.
> The figure must be black-and-white.
> I was able to produce a figure with some shades of grey (less than fifty,
> admitedly).
> However, the legend is still in red color.
> I need the legend be in black color.
> How can I get rid of the red color in the legend produced by'corrplot'?

See the help page ?corrplot.  It appears that the ... argument to
corrplot.mixed can be any of the arguments to corrplot, and tl.col seems
to default to red.

Duncan Murdoch


>
> Thank you in advance,
> Antonello Preti
>
> Here some code for exemplification.
>
>
> ### call the library
>
> library(corrplot)
> library(RColorBrewer)
>
> ### toy dataset
>
> data(mtcars)
>
> ### assign the dataset to a vector
>
> dat <- mtcars
>
> ### corrplot with shades of grey
>
> corrplot.mixed(cor(dat), col = rev(brewer.pal(10, "Greys")))
> title("\nCollinearity when r > 0.8")
>
> 	[[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.
>



More information about the R-help mailing list