Calculate mean and std dev from experiment - no formal params

I am a little lost on how to calculate mean and std dev from an experiment (simulation).

I have run the simulation (10000 times) and it output a set of numbers (10000). Plotting a histogram, it gives me what seems to be a normal distribution. I have used the mean and sd commands and they give me this values.

Mean: 9.3982000000
SD:1.2341137549


Then I have done an outer loop and rerun a 1000 times the sd and stddev calculus, running 200 times each experiment, so that I could use the mean of means and mean of stds.

- 1000 times
- 200 times
draw a number based on an algorithm


one of the outputs

Mean: 9.37336000000
SD:1.2125620067


Is this the right way to do it? I cannot find a mean and std value that is always the same. They are close, but not the same. Am I missing some detail or it is expected (this is what confidence interval is about) and the way to do it?

I don't have other formal parameters for calculus. Each number is a return of a program.

• What is it that you actually want to achieve here? What is the ultimate goal of this project? – gung Jul 17 '15 at 18:13
• Although you do not describe the nature of your "simulation," presumably it included some random values. What is randomness if not the potential to vary? Why, then, do you seem surprised that the simulation results vary? – whuber Jul 17 '15 at 19:30
• The ultimate goal is to find the maximum number of different Nets I may have following a specific linkage rule. I wanted to get the exact mean and sd of it, but I am in doubt if the way I am doing is right and if "exact" is not possible. – Adriano Almeida Jul 17 '15 at 22:37