# Generate example data variance and biased variance [closed]

I'd like to generate some example data for this equation related to Bessel's correction. What is a way to generate data for first part of the equation (in the picture below). One way to approach is to come up with a vector, like x= {1,2,3} and do the Expected Value of Variance[x] - the biased variance. But, I had trouble understanding whether the Variance function uses n-1, so would it be the sigma^2 or Sbiased^2?

That is, in some way it would be ExpectedValue{x - sbiased}, where x is a matrix of something like x={{1,2,3}, {4,5,6}}.

I'm new to Mathematica (and stack overflow mathematica) and appreciate any help and advice if I posted a question in the wrong way. Thank you ## closed as off-topic by wolfies, MarcoB, m_goldberg, LCarvalho, xzczdJul 2 '17 at 9:30

• The question does not concern the technical computing software Mathematica by Wolfram Research. Please see the help center to find out about the topics that can be asked here.
If this question can be reworded to fit the rules in the help center, please edit the question.

• you might want to consider it posting on the mathematics forum because it seems like you do not have any problem with the code but the mathematics (for which there is a dedicated forum). – Ali Hashmi Feb 28 '17 at 23:33
• tom, if you agree with Ali Hashmi I can move your question to Mathematics; let me know in these comments, or flag your post for moderator attention. – Mr.Wizard Feb 28 '17 at 23:37
• Thanks for suggestion. I want to make sure people in mathematics can tell me how to do it in mathematica. If that's the case, sure, please migrate it to any forum you think is best – tom Mar 1 '17 at 2:19
• You would have to know the population mean $\mu$, and the distribution that the data comes from, in order to generate some sample data. If you would like to specify the distribution (e.g. $N(\mu, \sigma^2)$ ), then the question can be answered. You might also want to change your question from seeking the 'best' way, to different ways ... since 'best' is a restriction you probably don't intend, and hard to pin down. – wolfies Mar 1 '17 at 2:28
• I'm voting to close this question as off-topic because the issue it raises is not a Mathematica issue but a mathematics issue. – m_goldberg Jun 29 '17 at 15:51

r[n_, k_] := RandomVariate[NormalDistribution[], {n, k}] 