I have a dataset of energy demand with a small sample size:
>dput(dat.demand2050.unique)
c(79, 56, 69, 61, 53, 73, 72, 86, 75, 68, 74.2, 80, 65.6, 60, 54)
with a density function that looks like this:
The data comes from a number of studies and can be separated into two "regimes" - low and high, which can be seen in the density function. However, I know that the data is biased toward a particular group of studies.
I want to generate a large number of random samples of data that will be an input to a simulation study. I am debating between a choice of three approaches:
1.Model the density function using the normalmixEM()
function from the mixtools()
package, which gives the following result: (related post here https://stackoverflow.com/questions/17924976/fitting-multimodal-distributions-in-r-generating-new-values-from-fitted-distrib)
the caveat being that I am forcing a strict normality assumption on my underlying process.
OR
2.Generating a random sample from a uniform distribution i.e assuming each observation is equi-probable:
NN = 1000 #a number
set.seed(99)
dat.demand2050.random <- runif(NN,min=min(dat.demand2050.unique),max=max(dat.demand2050.unique))
which gives the following density function:
densityplot(dat.demand2050.random)
OR
3.Use sample()
with replacement:
dat.demand2050.random2 <- sample(dat.demand2050.unique,NN,replace=TRUE)
densityplot(dat.demand2050.random2)
So my question is, what are the pros and cons of these approaches and what criteria should I apply for choosing the correct one?