Questions tagged [quantile]

Quantiles are points taken at regular intervals from the cumulative distribution function (CDF) of a random variable.

In scientific software for statistical computing and graphics, the quantile of a numeric vector can be found by function quantile.

755 questions
0
votes
1 answer

Rcpp: convenient use of comparators

I am beginner in use of Rcpp and I want get faster selection of values of vectors after calculation of quantiles. In the example below, it runs well when lower and higher limits calculated by qnorm function are manually entered (function val.sel.1).…
0
votes
0 answers

Plotting a line graph with scale.quantile()

I am trying to plot a sorted array of normally distributed data so that it plots as straight line. I would like to do this using a cumulative density function, which I think is also known as a quantile function. Unfortunately, I haven't found many…
tbcholla
  • 33
  • 6
0
votes
2 answers

What's wrong with my survival object?

I have a survival object in R. print(surv) gives me > print(surv) Call: survfit(formula = Surv(TAGE, EVENT) ~ 1, data = data_LTC[data_LTC$TYPE == "Job", ]) records n.max n.start events median 0.95LCL 0.95UCL 299510 299510 299510 …
speendo
  • 13,045
  • 22
  • 71
  • 107
0
votes
1 answer

Testing slope in quantile regression

I am using quantreg package in R for running quantile regression (95%) on a set of data. I would like to set the slope of of the quantile regression to the value 1.4, as alreday did in a previous analysis with which I want to compare my outcomes. If…
refroll
  • 131
  • 1
  • 9
0
votes
1 answer

How to draw a 95% confidence interval (area) for residuals on a normal probability Q-Q plot in SAS?

Under the 'CI area' I mean smth. like the one plotted on graphs in @cbeleites' answer or depicted in Ron Pearson's post.: Thank you.
abc
  • 167
  • 1
  • 4
  • 18
0
votes
2 answers

Quantile function causing error in MATLAB

I am using quantile function in the simplest form: x = [1.2,3,4,5]; y = quantile(x,0.5); But I get the error: Undefined function 'quantile' for input arguments of type 'double'. I was not having this error in MATLAB R2009a but get this error in…
0
votes
1 answer

R: calling rq() within a function and defining the linear predictor

I am trying to call rq() of the package quantreg within a function. Herebelow is a simplified explanation of my problem. If I follow the recommendations found at http://developer.r-project.org/model-fitting-functions.txt, I have a design matrix…
user1431694
  • 715
  • 1
  • 11
  • 22
-1
votes
2 answers

Finding outliers in a scatter plot / pandas dataframe?

I am creating an interactive scatter plot which has thousands of data points, and I would like to dynamically find the outliers, in order to annotate only those points which are not too bunched together. I am doing this currently in a slightly…
am1234
  • 93
  • 1
  • 9
-1
votes
1 answer

Create this simple array

I have two one-dimensional arrays u and q as follows: import numpy as np n = 300 u1 = np.random.uniform(0.5, 4.5, size=n) u2 = 2 / u1 + np.random.normal(scale=0.09, size=n) u = np.array([u1,u2]) and d=np.random.uniform(0.0, np.pi, size=100) q…
Mahtab
  • 121
  • 4
-1
votes
1 answer

SAS Code On Ranking Exam Performance Using Conditional Quantile Regression

I'm relatively new to R and coding in general and I have been trying to replicate an example provided in this PDF (https://support.sas.com/resources/papers/proceedings17/SAS0525-2017.pdf) on quantile regressions in SAS. The example can be found on…
-1
votes
1 answer

How I can select data that is above the third quartile in a R-DataFrame

I would like to select cases with values in some variables above the corresponding third quartile (3) As my dataset is very large I am going to take as an example the 'Air Quality' database that comes in R. df <-…
-1
votes
1 answer

How to include/map calculated percentiles to the result dataframe?

I'm using spark-sql-2.4.1v, and I'm trying to do find quantiles, i.e. percentile 0, percentile 25, etc, on each column of my given data. As I am doing multiple percentiles, how to retrieve each calculated percentile from the results? My dataframe…
BdEngineer
  • 2,929
  • 4
  • 49
  • 85
-1
votes
1 answer

How to Convert daily dataset to monthly dataset with 95% quantile values in the monthly format?

I have a timeseries of daily dataset for 10 years. I want to convert it to monthly dataset for 10 years, however the monthly values will be quantiles rather than the average of that month. How to perform this using R?
-1
votes
2 answers

Removing na from column during summarize_at and funs before performing function

I have repeating dates, a column for returns, and then many other columns of other variables that I am trying to sort on and then extract the average return of the top quartile of the sorted variable constituents for each date. There are NA's and I…
Kskiaskd
  • 35
  • 5
-1
votes
1 answer

Quantile function in matlab

How does quantile function work in matlab? for example: x=[3;14;9;18;5;10;13;20;1]; and A=quantile(X,2), we get two results in A i.e A=[7;13.5].