[R] main plot title

marciarr marcia.rocha at gmail.com
Fri Nov 30 03:53:59 CET 2007


Hi Jim,
Thanks for your answer.
Unfortunately, because the x of my plot function is not actually waht I need
on my graph's title, your advice does not work. Thanks anyway,
Marcia

jholtman wrote:
> 
> hopefully this will help you:
> 
> mydata <- 1:10
> my.plot <- function(x) plot(x, main=paste('dataset =',
> deparse(substitute(x))))
> my.plot(mydata)
> 
> 
> On Nov 29, 2007 9:05 PM, marciarr <marcia.rocha at gmail.com> wrote:
>>
>> Dear R users,
>> I am having a problem with the main title of a plot. I have written a
>> function returning a plot and I would like that the main title of this
>> plot
>> shows actually the name of the dataset I have used. So, for instance: if
>> my
>> dataset is called Chl, I would like that my plot to be entitled : "Raw
>> periodogram of Chl". I know the function "paste". I suppose I would be
>> looking for something like: plot(main=paste(""Raw periodogram of", "...).
>> How can the program understand that the name of the data set is supposed
>> to
>> go there?
>> Thank you very much for your answers!!!
>> Marcia
>> --
>> View this message in context:
>> http://www.nabble.com/main-plot-title-tf4901182.html#a14039291
>> Sent from the R help mailing list archive at Nabble.com.
>>
>> ______________________________________________
>> R-help at r-project.org 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.
>>
> 
> 
> 
> -- 
> Jim Holtman
> Cincinnati, OH
> +1 513 646 9390
> 
> What is the problem you are trying to solve?
> 
> ______________________________________________
> R-help at r-project.org 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.
> 
> 

-- 
View this message in context: http://www.nabble.com/main-plot-title-tf4901182.html#a14039701
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list