# TDist 脚本和图表功能

`TDist()` 用于返回学生 `t` 分布的概率，其中数值是一个将要为其计算概率的 `t` 的计算值。

语法：

TDist(value, degrees\_freedom, tails)

返回数据类型： 数字

参数：

参数

| 参数 | 描述 |
| --- | --- |
| value | 您想要用于评估分布的值。值必须不能为负数。 |
| degrees\_freedom | 表示自由度数的正整数。 |
| tails | 必须为 1（单尾分布）或 2（双尾分布）。 |

此函数通过以下方式与 TInv 函数关联：   
`If prob = TDIST(value, df ,2), 
 then TINV(prob, df) = value`

限制：

所有参数均必须为数字，如不是则会返回 NULL 值。

[](https://help.qlik.com/en-US/cloud-services/Subsystems/Hub/Content/Sense_Hub/Scripting/StatisticalDistributionFunctions/TDist.htm)

#### 示例和结果：

| 示例 | 结果 |
| --- | --- |
| TDIST(1, 30, 2) | 返回 0.3253 |

## 了解详情

* [TInv 脚本和图表功能](https://help.qlik.com/zh-CN/cloud-services/Subsystems/Hub/Content/Sense_Hub/Scripting/StatisticalDistributionFunctions/TInv.htm)