Goal
Learn how to generate normal distributed random values with a standard deviation of 1.
Learn
To generate approximately normal distributed random values with mean of 6 and standard deviation of 1, you can use a method called Zwölferregel, which is based on the Central limit theorem.
Step-by-step
- Create an empty workbook.
- Apply EXPLODE_RANGE(1;10) to the first column the formula and name the column
Range.
- Apply RAND() to the second column and name the column
Rand1.
- Proceed further up to the point where you have a column named
Rand12.
- Apply to the last column the formula SUM(#Rand1;#Rand2;#Rand3;#Rand4;#Rand5;#Rand6;#Rand7;#Rand8;#Rand9;#Rand10;#Rand11;#Rand12) and name the column
Sum1to12.
- Adjust the range to your needs, i.e. by changing it to EXPLODE_RANGE(1;10000).
Future Versions
As of Datameer version 5.8 a function RANDGAUSSIAN can generate normal distributed random values with mean of 0 and standard deviation of 1. You can also look into the NORMDIST function.
For quick reference, find attached the final version which is uploadable via REST API. It does not have any dependencies.
Attachement
Comments
0 comments
Please sign in to leave a comment.