Labels in char.Scatter PerformanceAnalytics

I am trying to add some labels to the x and y axis in the chart.Scatter plot from the PerformanceAnalytics package but it does not seem to work. Ideally, I would like to generate a chart with either a rug or an histogram on the y & x axis, so chart.Scatter seemed to be a good function but it does not work for me as I can't label the axis...

chart.Scatter(runif(100, 5.0, 7.5),runif(100, 5.0, 7.5),xlab="Series A",ylab="Series B",main="random xy")

Any ideas?


You could temporarily set the color of the axis labels to "white" (or "transparent") using par and subsequently add the customized axis labels.


par(col.lab = "white")
chart.Scatter(runif(100, 5.0, 7.5), runif(100, 5.0, 7.5), main="random xy")

par(col.lab = "black")
title(xlab = "Series A", ylab = "Series B")

Need Your Help

Explicit constructor call in C++


1) what is the return value of following statement: