How can I get random drawings from a list with data in the range of mean + - 1 standard deviation?
I know how to do it for a theoretical normal distribution
with(Statistics);
S := Sample(RandomVariable(Normal(0, 1)), 1000)
but not for an empirical distribution....

Empirical distribution
Do you mean something like this?
Thanks Robert! It looks good
Thanks Robert! It looks good taken at face value.
I just realized though (correct me if I am wrong) that even if we sample a random
drawings from for example serial dependent data (empirical data) we still wont get serial correlated drawings, or?.
It would be nice to find a way to collect empirical data, calculate the returns,
sample a sequence of the returns ( with the original statistical properties such as serial correlation)
and then use that sample to simulate a unit root.
I mean I can due it with
I mean I can due it with brutal force by simply collecting data
calculate the serial correlation coefficient of the returns and then use the below code to calculate serial dependent drawings
restart:
randomize():
with(Statistics):
n:=1000:
p := .7; # serial correlation
r := Sample(RandomVariable(Normal(0, 1)), n);
for i from 2 to n do
x[1] := 0; x[i] := p*x[i-1]+r[i] end do;
rr := [seq(x[i], i = 1 .. n)]
Correlation(rr[1 .. n-1], rr[2 .. n])
but there must be an more elegant version? maybe Bootstaping?!