How do you label Xtick and Ytick marks with Currency symbols: $2000
instead of 2000? I would like to add dollar symbols to tickmarks on
boxplots, histograms and back-to-back histograms.
My Examples (requiring the lattice and Hmisc packages):
data(case0102, package="Sleuth2")
str(case0102)
boxplot(Salary~Sex, case0102)
histogram(~ Salary | Sex, data=case0102)
require(Hmisc)
# out <- histbackback(split(case0102$Salary, case0102$Sex),
probability=TRUE, xlim=c(-.001,.001),
out <- histbackback(split(case0102$Salary, case0102$Sex),
probability=FALSE, xlim=c(-30,30),
main = 'Sleuth Case 1.2')
#! just adding color
barplot(-out$left, col="red" , horiz=TRUE, space=0, add=TRUE,
axes=FALSE)
barplot(out$right, col="blue", horiz=TRUE, space=0, add=TRUE,
axes=FALSE)
[[alternative HTML version deleted]]
______________________________________________
[email protected] 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.