I want to merge the three graphs below using the plot
function. I do the basics starting with the command par(mfrow=c(1,3))
but I can not join them.
The problem I believe is that it is using a direct summary object of the quantitative regression.
Could you help me with this?
library(quantreg)
data(engel)
x1 <- engel$income
x2 <- 0.5*engel$income*2^(0.3)
x3 <- engel$income*3^(2)
fit1 <- rq(foodexp ~ x1, tau=seq(0.05, 0.95, by = 0.05), method="br", data=engel)
fit2 <- rq(foodexp ~ x2, tau=seq(0.05, 0.95, by = 0.05), method="br", data=engel)
fit3 <- rq(foodexp ~ x3, tau=seq(0.05, 0.95, by = 0.05), method="br", data=engel)
fit1_betas <- summary(fit1, se="iid")
fit2_betas <- summary(fit2, se="iid")
fit3_betas <- summary(fit3, se="iid")
par(mfrow=c(1,3))
plot(fit1_betas, parm=2, main=expression("Regression": beta[0]), ylab="beta", xlab = "tau", cex=1, pch=20)
plot(fit2_betas, parm=2, main=expression("Regression": beta[0]), ylab="beta", xlab = "tau", cex=1, pch=20)
plot(fit3_betas, parm=2, main=expression("Regression": beta[0]), ylab="beta", xlab = "tau", cex=1, pch=20)