0

I am trying to rename title of each plot in multiple plots from R summary objects. I do quintile regression and I'd like to plot coefficients. I do the following

qr.1 <-summary( rq (y ~ x1+x2, tau=5:95/100, data=mydata))
plot(qr.1)

plot(qr.1) gives me plots of the coefficients of x1 and x2. But the title in each plot is x1 and x2. I like to change the title from x1 into variable name (e.g. income per capita). I tried several standard approaches but failed. I think this is because i plot summary objects. Do you guys know how to add title in multiple plots from summary objects?

Thanks

yudo

lmo
  • 37,904
  • 9
  • 56
  • 69
yudo
  • 1
  • 1
  • Is it feasible to just add `main=`, `xlab=`, and `ylab=` in each call to `plot()`? – Alex A. Apr 13 '15 at 15:28
  • I did that. But it gives the same title for each plot. For example I did plot(q1.r, main="income per capita"). Then, this becomes title for x1 and x2. What I want is different titles for different plots. But i don't how to do this in summary objects. – yudo Apr 13 '15 at 15:49

1 Answers1

0

I finally found out how to deal with this. As Alex mentioned, i did the following

plot(qr.1, par=c(1,2), main=c("Income Per capita", "Health Expenditure"), xlab="tau")
yudo
  • 1
  • 1