[R] spacing problem in main title using car package scatterplot
    Gerard Smits 
    g_smits at verizon.net
       
    Thu Aug 29 23:00:21 CEST 2013
    
    
  
Hi All,
I'm using R 3.0.0.  I'm trying to add the sample size of the paired data (calculated by a function n(), which returns a value of 70, correctly).
My main title works fine except that the '70' appears far to the right on the line as in:
  at Month 18 (N=                                       70)
Is there a way of left justifying the result of .(ss)?  or some other way of removing with whitespace between n= and 70?.
Thanks for any suggestions.
Gerard
library (car)
data<-read.csv("//users//smits//r_work//data.csv", header = TRUE)
attach(data);
##################################################################################################################
ss<-n(m18_das28*b_score)
scatterplot(m18_das28~b_score,
     jitter=list(x=1, y=1),
     grid=F,
     smooth=F,
     las=1,
     pch=c(1),
     col='blue',
     main=bquote(paste("Hypothesis 9.4.1\nBaseline XYZ with Disease Activity (DAS28)\nat Month 18 (N=",.(ss),")")),
     xlab="Baseline XYZ", 
     ylab="Month 18 DAS28",
     legend.plot=F)
    
    
More information about the R-help
mailing list