I want to access p-values of quantile regression with multiple quantiles.
fit2 <- rq(speed ~ vsby_avg + snwd_avg, tau=c(.05, 0.95), data = test_data)
fit2_summ <- summary(fit2)
The str(fit2_summ)
gives the following result
List of 2
$ :List of 6
..$ call : language rq(formula = speed ~ vsby_avg + snwd_avg, tau = c(0.05, 0.95), data = test_data)
..$ terms :Classes 'terms', 'formula' language speed ~ vsby_avg + snwd_avg
.. .. ..- attr(*, "variables")= language list(speed, vsby_avg, snwd_avg)
..$ coefficients: num [1:3, 1:4] 57.63195 0.13474 -0.00337 0.1919 0.01212 ...
I am not able to access the p-values for the 50th and 95th quantile using fit2_summ$coefficients[,4]
because the summary model is present for 2 quantiles rather than a single quantile, in which case the above command would have worked.