Skip to main content
3 of 3
added 376 characters in body
Yves Klett
  • 15.5k
  • 5
  • 58
  • 125

If you want recursive (not performance, mind):

dat = Round@RandomVariate[NormalDistribution[1000, 0.1*1000], 8];

rec[dat_] := 
 Append[dat[[2 ;; -1]], 
  Round@RandomVariate[NormalDistribution[1000, 0.1*1000]]]

NestList[rec, dat, 10]//Grid

Mathematica graphics

ach well, here cometh the color:

dat = MapIndexed[Style[#, Hue[#2[[1]]/8]] &, 
   Round@RandomVariate[NormalDistribution[1000, 0.1*1000], 8]];

NestList[rec, dat, 10] // Grid

Mathematica graphics

As for a two-argument function:

k = 1;
dat = Round@RandomVariate[NormalDistribution[1000, k*1000], 8];

rec[dat_, k_] := 
 Append[dat[[2 ;; -1]], 
  Round@RandomVariate[NormalDistribution[1000, k*1000]]]

NestList[rec[#, k] &, dat, 10] // Grid

Mathematica graphics

Yves Klett
  • 15.5k
  • 5
  • 58
  • 125