[R] Simulate skewed data if 2.5, 25th 50th and 75 centile are known

John Sorkin jsorkin at grecc.umaryland.edu
Wed Aug 5 22:54:40 CEST 2015


Colleagues,
I need to simulate skewed data so I can run a sample size calculation.
 
I know the 2.5th, 25th, 50th, and 75th centiles of the data (32, 43, 48, 250).
 
data <- matrix(c(75,250,50,48,25,43,2.5,32),nrow=4,ncol=2,byrow=TRUE)
dimnames(data) <- list(NULL,c("x","y"))
data

Is there a way I can use these values to generate simulations of the original data? Of course if the data were normally distributed this would be a piece of cake, but given the skewness, I don't know how to go about the generating the values that would be expected from a distribution having the observed values at the four centiles.
Thank you,
John
John David Sorkin M.D., Ph.D.
Professor of Medicine
Chief, Biostatistics and Informatics
University of Maryland School of Medicine Division of Gerontology and Geriatric Medicine
Baltimore VA Medical Center
10 North Greene Street
GRECC (BT/18/GR)
Baltimore, MD 21201-1524
(Phone) 410-605-7119
(Fax) 410-605-7913 (Please call phone number above prior to faxing) 

Confidentiality Statement:
This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message. 


More information about the R-help mailing list