Try aes_string:
geom_density(aes_string(PrecisionColumnName, fill = "Label"), alpha = 0.2)
I assume this is part of a function or loop, where PrecisionColumnName
is a string that gives the name of the variable you want to plot.
Hadley
> --
> You received this message because you are subscribed to the ggplot2 mailing list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
> To unsubscribe: email ggplot2+u...@googlegroups.com
> More options: http://groups.google.com/group/ggplot2
>
--
Assistant Professor / Dobelman Family Junior Chair
Department of Statistics / Rice University
http://had.co.nz/