[R] Show date on graph
Uwe Ligges
ligges at statistik.uni-dortmund.de
Wed Dec 6 08:34:41 CET 2006
Syed Abid Hussaini wrote:
> I have a character "2006-11-06" which was originally scanned from a csv file. This character is
> named date. I now use mtext (date) on a plot and i see strange cluttered characters instead of
Then it is not a character but some date/time object such as a POSIXlt
class. mtext() does not have an appropriate method for it. If this date
is x, just plot as.character(x) instead.
Uwe Ligges
> 2006-11-06. I tried many ways but i dont know whats going on. Then for testing i made an
> artificial character d <- ("2006-11-06") and now when i do mtext (d) it shows up on the plot.
> While both date and d return "2006-11-06" only d shows up on the plots. Any help would be appreciated.
>
>
>
> ____________________________________________________________________________________
> Have a burning question?
> Go to www.Answers.yahoo.com and get answers from real people who know.
>
> ______________________________________________
> R-help at stat.math.ethz.ch 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.
More information about the R-help
mailing list