diff --git a/extensions/community/Statistics.json b/extensions/community/Statistics.json new file mode 100644 index 000000000..b3bc7c39e --- /dev/null +++ b/extensions/community/Statistics.json @@ -0,0 +1,1519 @@ +{ + "author": "", + "category": "General", + "extensionNamespace": "", + "fullName": "Normal Distribution Statistics", + "gdevelopVersion": "", + "helpPath": "https://wiki.gdevelop.io/gdevelop5/tutorials/randomness/#chose-better-random-sequences", + "iconUrl": "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0ibWRpLWNoYXJ0LWJlbGwtY3VydmUiIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNOS45NiwxMS4zMUMxMC44Miw4LjEgMTEuNSw2IDEzLDZDMTQuNSw2IDE1LjE4LDguMSAxNi4wNCwxMS4zMUMxNywxNC45MiAxOC4xLDE5IDIyLDE5VjE3QzE5LjgsMTcgMTksMTQuNTQgMTcuOTcsMTAuOEMxNy4wOCw3LjQ2IDE2LjE1LDQgMTMsNEM5Ljg1LDQgOC45Miw3LjQ2IDguMDMsMTAuOEM3LjAzLDE0LjU0IDYuMiwxNyA0LDE3VjJIMlYyMkgyMlYyMEg0VjE5QzcuOSwxOSA5LDE0LjkyIDkuOTYsMTEuMzFaIiAvPjwvc3ZnPg==", + "name": "Statistics", + "previewIconUrl": "https://asset-resources.gdevelop.io/public-resources/Icons/864a93d4274c7c7c62e95b113c4cfe061df2363cadc747ba02de8e43aed57fce_chart-bell-curve.svg", + "shortDescription": "Basic statistcs functions for normal distributions.", + "version": "1.1.0", + "description": [ + "Its main function is the \"normal random number generator\" (NormalRNG). This function generates a random number that follows a normal (bell-shaped) distribution. Such distribution has a central tendency value (mean) and a margin of deviation (standard deviation, or StdDev). NormalRNG is bounded so that extreme values (abnormally high or small numbers, called outliers) do not occur.", + "", + "This extension also includes a library of common values to check for probability, be it the chance of being above a certain number (\"One-Tail\"), the chance of being different to a population (\"Two-tails\"), or the chance of being in a range. Probabilities are given in percentage and coded as pXXX. For example, p950 gives the 95.0% probability.", + "", + "As support, the extension also can generate Z-values (distance between the mean and the number, measured in StdDev), calculate and compare them with others (as Z-Scores).", + "", + "This covers the basics on normal distributions. For an implementation example take a look here:", + "https://gd.games/arelaestudio/statistics-example", + "", + "Principles of randomness can be found in:", + "https://wiki.gdevelop.io/gdevelop5/tutorials/randomness/#chose-better-random-sequences", + "", + "Foundations on the extension can be found here:", + "https://en.wikipedia.org/wiki/Normal_distribution#Computational_methods", + "https://en.wikipedia.org/wiki/Irwin%E2%80%93Hall_distribution", + "https://en.wikipedia.org/wiki/One-_and_two-tailed_tests", + "https://en.wikipedia.org/wiki/Standard_score" + ], + "tags": [ + "random", + "probability", + "statistics" + ], + "authorIds": [ + "JJYR7q4MEBS2ap7ziDiYGlY40Fi2" + ], + "dependencies": [], + "globalVariables": [], + "sceneVariables": [ + { + "name": "pCheck", + "type": "number", + "value": 0 + }, + { + "folded": true, + "name": "OneTail", + "type": "structure", + "children": [ + { + "name": "p010", + "type": "number", + "value": -2.32634787404 + }, + { + "name": "p025", + "type": "number", + "value": -1.95996398454 + }, + { + "name": "p050", + "type": "number", + "value": -1.64485362695 + }, + { + "name": "p083", + "type": "number", + "value": -1.38299434452 + }, + { + "name": "p100", + "type": "number", + "value": -1.28155156554 + }, + { + "name": "p125", + "type": "number", + "value": -1.15034938038 + }, + { + "name": "p150", + "type": "number", + "value": -1.03643338949 + }, + { + "name": "p167", + "type": "number", + "value": -0.96742159278 + }, + { + "name": "p200", + "type": "number", + "value": -0.84162123357 + }, + { + "name": "p250", + "type": "number", + "value": -0.6744897502 + }, + { + "name": "p300", + "type": "number", + "value": -0.52440051271 + }, + { + "name": "p333", + "type": "number", + "value": -0.43072730021 + }, + { + "name": "p350", + "type": "number", + "value": -0.38532046641 + }, + { + "name": "p375", + "type": "number", + "value": -0.31863936396 + }, + { + "name": "p400", + "type": "number", + "value": -0.25334710314 + }, + { + "name": "p417", + "type": "number", + "value": -0.21042841133 + }, + { + "name": "p450", + "type": "number", + "value": -0.12566134686 + } + ] + }, + { + "folded": true, + "name": "TwoTails", + "type": "structure", + "children": [ + { + "name": "p683", + "type": "number", + "value": 1 + }, + { + "name": "p750", + "type": "number", + "value": 1.15034938038 + }, + { + "name": "p900", + "type": "number", + "value": 1.64485362695 + }, + { + "name": "p950", + "type": "number", + "value": 1.95996398454 + }, + { + "name": "p990", + "type": "number", + "value": 2.57582930355 + }, + { + "name": "p997", + "type": "number", + "value": 3 + }, + { + "name": "p999", + "type": "number", + "value": 6 + } + ] + }, + { + "name": "ZScore", + "type": "number", + "value": 0 + } + ], + "eventsFunctions": [ + { + "description": "Generates a random number that follows a normal distribution. Bound to avoid extreme values.", + "fullName": "Normalized random number", + "functionType": "Expression", + "name": "NormalRNG", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "clamp(Mean+(StdDev*Statistics::Zvalue()), Mean-(StdDev*TwoTails[Bounds]), Mean+(StdDev*TwoTails[Bounds]))" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Mean", + "name": "Mean", + "type": "expression" + }, + { + "description": "Standard deviation (1 sigma)", + "name": "StdDev", + "type": "expression" + }, + { + "description": "Bounds (p997 recommended)", + "name": "Bounds", + "supplementaryInformation": "[\"p683\",\"p750\",\"p900\",\"p950\",\"p990\",\"p997\",\"p999\"]", + "type": "stringWithSelector" + } + ], + "objectGroups": [] + }, + { + "description": " the probability of the number against a normal distribution.", + "fullName": "One-Tail test", + "functionType": "ExpressionAndCondition", + "name": "OneTail", + "sentence": "_PARAM1_ chance of being _PARAM4_ against a normal distribution (Mean:_PARAM2_; StdDev:_PARAM3_)", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "ZScore", + "=", + "Statistics::ZScore(NumberToCheck,Mean,StdDev)" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + "<", + "OneTail.p010" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "0" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p010" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "1" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p025" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "2.5" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p050" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "5" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p083" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "8.33" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p100" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "10" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p125" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "12.5" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p150" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "15" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p167" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "16.67" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p200" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "20" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p250" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "25" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p300" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "30" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p333" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "33.33" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p350" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "35" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p375" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "37.5" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p400" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "40" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p417" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "41.67" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "OneTail.p450" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "45" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "50" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p450" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "55" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p417" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "58.33" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p400" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "60" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p375" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "62.5" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p350" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "65" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p333" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "66.66" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p300" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "70" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p250" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "75" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p200" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "80" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p167" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "83.33" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p150" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "85" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p125" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "87.5" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p100" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "90" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p083" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "91.67" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p050" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "95" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p025" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "97.5" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "-OneTail.p010" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "99" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "ZScore", + ">", + "3" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "pCheck", + "=", + "100" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "Type", + "=", + "\"bigger\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "pCheck" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "Type", + "=", + "\"smaller\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "100-pCheck" + ] + } + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Number to be checked", + "name": "NumberToCheck", + "type": "expression" + }, + { + "description": "Mean", + "name": "Mean", + "type": "expression" + }, + { + "description": "Standard deviation (1 sigma)", + "name": "StdDev", + "type": "expression" + }, + { + "description": "Type of check", + "name": "Type", + "supplementaryInformation": "[\"bigger\",\"smaller\"]", + "type": "stringWithSelector" + } + ], + "objectGroups": [] + }, + { + "description": "if the number is different from a given normal distibution with confidence.", + "fullName": "Two-Tail test", + "functionType": "Condition", + "name": "TwoTails", + "sentence": "_PARAM1_ is different to the normal distribution (Mean:_PARAM2_; StdDev:_PARAM3_) at a _PARAM4_ confidence level", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BuiltinCommonInstructions::CompareNumbers" + }, + "parameters": [ + "abs(Statistics::ZScore(NumberToCheck,Mean,StdDev))", + ">=", + "TwoTails[Confidence]" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Number to be checked", + "name": "NumberToCheck", + "type": "expression" + }, + { + "description": "Mean", + "name": "Mean", + "type": "expression" + }, + { + "description": "Standard deviation (1 sigma)", + "name": "StdDev", + "type": "expression" + }, + { + "description": "Confidence level (p950 recommended)", + "name": "Confidence", + "supplementaryInformation": "[\"p683\",\"p750\",\"p900\",\"p950\",\"p990\",\"p997\",\"p999\"]", + "type": "stringWithSelector" + } + ], + "objectGroups": [] + }, + { + "description": " the probability of being inside a range.", + "fullName": "Probability range", + "functionType": "ExpressionAndCondition", + "name": "Range", + "sentence": "The probability between _PARAM1_ and _PARAM2_ in a normal distribution (Mean:_PARAM3_; StdDev:_PARAM4_)", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "Statistics::OneTail(Max, Mean, StdDev, \"bigger\") - Statistics::OneTail(Min, Mean, StdDev, \"bigger\")" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Lower limit of the range", + "name": "Min", + "type": "expression" + }, + { + "description": "Upper limit of the range", + "name": "Max", + "type": "expression" + }, + { + "description": "Mean", + "name": "Mean", + "type": "expression" + }, + { + "description": "Standard deviation (1 sigma)", + "name": "StdDev", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": " the Z-Score of a number in a normal distribution.", + "fullName": "Z-Score", + "functionType": "ExpressionAndCondition", + "name": "ZScore", + "sentence": "The Z-Score of _PARAM1_ in the normal distribution (Mean:_PARAM2_; StdDev:_PARAM3_)", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "(NumberToCheck-Mean)/StdDev" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Number to be checked", + "name": "NumberToCheck", + "type": "expression" + }, + { + "description": "Mean", + "name": "Mean", + "type": "expression" + }, + { + "description": "Standard deviation (1 sigma)", + "name": "StdDev", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "Provides the Z value used for normal random number generation.", + "fullName": "Z-value", + "functionType": "Expression", + "name": "Zvalue", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "(RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1)+RandomFloat(1))-6" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + } + ], + "eventsBasedBehaviors": [], + "eventsBasedObjects": [] +} \ No newline at end of file