从图中可以看到,P(x)大的玩家可能是正常玩家(左上角的点),反之是异常玩家。
下面要像更加精确的用数字来表达这个事情,就要用的MLE:
Assuming the data points is sampled from a probability density function fθ(x)
θ determines the shape of fθ(x)
θ is unknown, to be found from data
1.数学计算类啊
要找θ∗ 使得PDF最大:
我们假设分布是高斯分布
这个分布看上去很复杂,但是我们只需要把它看做是输入为向量x,输出是这个向量x被sample到的几率。Input: vector x, output: probability density of sampling x.
θ which determines the shape of the function are mean μ and covariance matrix Σ
公式(1)就可以写成:
公式(2)可以写成:
注:当然,也可以假设参数θ不是高斯分布产生的,可以是更加复杂的网络参生的
μ ∗,Σ ∗ 可以直接根据MLE的公式算出来,直接贴结果:
最后就可以把x代入下面的判断条件,来决定是否是异常玩家。
可视化后:
The colors represents the value of fμ∗,Σ∗(x) ,颜色月红越正常,越浅越异常。
由于我们是用向量来表示x,因此我们可以考虑不止两个维度:
x1 : Percent of messages that are spam (說垃圾話)
x2: Percent of button inputs during anarchy mode (無政府狀態發言)
x3 : Percent of button inputs that are START (按 START鍵)
x4 : Percent of button inputs that are in the top 1 group (跟大家一樣)
x5 : Percent of button inputs that are in the bottom 1 group (唱反調)
下面给三个实例,由于fμ∗,Σ∗(x)一般比较小,所以在前面加上log。