I have a data in the t vector and given the data I can get quantile
t = c(1,2,3,4,5,6,3,2,21,22,23,2,23,4,4,4444)
quantile(t,c(.3))
3
But I would like to do the opposite
I want provide 3 and have it return the quantile percentage
like somefunction(3,t)
and the output is 30%
Is there a function for that?