1.Rescaling
The simplest method is rescaling the range of features to scale the range in [0, 1] or [−1, 1]. Selecting the target range depends on the nature of the data. The general formula is given as:
这是最简单的一种处理方法,它使得所有特征的范围都在[0,1]或者[-1,1]。
x ′ = x − m i n ( x ) m a x ( x ) − m i n ( x ) x'=\frac{x-min(x)}{max(x)-min(x)} x′=max(x)−min(x)x−min(x)
其中: x x x是原始值, x ′ x' x′为规则化后的值
2.Mean normalisatio
x
′
=
x
−
m
e
a
n
(
x
)
m
a
x
(
x
)
−
m
i
n
(
x
)
x'=\frac{x-mean(x)}{max(x)-min(x)}
x′=max(x)−min(x)x−mean(x)
其中: x x x是原始值, x ′ x' x′为规则化后的值
3.Standardization
这个方法是机器学习中使用得最广泛的方法,它将使得标准化后的特征值的平均值为0,标准差为1.
x ′ = x − m e a n ( x ) σ x'=\frac{x-mean(x)}{\sigma} x′=σx−mean(x)
其中: x x x是原始值, x ′ x' x′为规则化后的值, σ \sigma σ为标准差