Mahalanobis Distance(马氏距离)
(from:http://en.wikipedia.org/wiki/Mahalanobis_distance)
Mahalanobis distance
In statistics, Mahalanobis distance is a distance measure introduced by P. C. Mahalanobis in 1936.It is based on correlations between variables by which different patterns can be identified and analyzed. It gauges similarity of an unknown sample set to a known one. It differs fromEuclidean distance in that it takes into account the correlations of the data set and is scale-invariant. In other words, it is a multivariateeffect size.
Definition
Formally, the Mahalanobis distance of a multivariate vector from a group of values with mean
and covariance matrix
is defined as:
(注:1.这个是X和总体均值的马氏距离。2.这里的S是可逆的,那么协方差矩阵不可逆的话怎么办?)
Mahalanobis distance (or "generalized squared interpoint distance" for its squared value) can also be defined as a dissimilarity measure between two random vectors and
of the same distribution with the covariance matrix
:
If the covariance matrix is the identity matrix, the Mahalanobis distance reduces to the Euclidean distance. If the covariance matrix is diagonal, then the resulting distance measure is called the normalized Euclidean distance:
where is the standard deviation of the
(
) over the sample set.
(源自:百度百科)
马氏优缺点:
Mahalanobis Distance(马氏距离)的更多相关文章
- paper 114:Mahalanobis Distance(马氏距离)
(from:http://en.wikipedia.org/wiki/Mahalanobis_distance) Mahalanobis distance In statistics, Mahalan ...
- Mahalanobia Distance(马氏距离)的解释
马氏距离有多重定义: 1)可以表示 某一个样本与DataSet的距离. 2)可以表示两个DataSet之间的距离. 1) The Mahalanobis distance of an observat ...
- 马氏距离(Mahalanobis distance)
马氏距离(Mahalanobis distance)是由印度统计学家马哈拉诺比斯(P. C. Mahalanobis)提出的,表示数据的协方差距离.它是一种有效的计算两个未知样本集的相似度的方法.与欧 ...
- MATLAB求马氏距离(Mahalanobis distance)
MATLAB求马氏距离(Mahalanobis distance) 作者:凯鲁嘎吉 - 博客园 http://www.cnblogs.com/kailugaji/ 1.马氏距离计算公式 d2(xi, ...
- Mahalanobis距离(马氏距离)的“哲学”解释
讲解教授:赵辉 (FROM : UESTC) 课程:<模式识别> 整理:PO主 基础知识: 假设空间中两点x,y,定义: 欧几里得距离, Mahalanobis距离, 不难发现,如果去掉马 ...
- 有关马氏距离和hinge loss的学习记录
关于度量学习,之前没有看太多相关的文献.不过南京的周老师的一篇NIPS,确实把这个问题剖析得比较清楚. Mahalanobis距离一般表示为d=(x-y)TM(x-y),其中x和y是空间中两个样本点, ...
- 基于欧氏距离和马氏距离的异常点检测—matlab实现
前几天接的一个小项目,基于欧氏距离和马氏距离的异常点检测,已经交接完毕,现在把代码公开. 基于欧式距离的: load data1.txt %导入数据,行为样本,列为特征 X=data1; %赋值给X ...
- Python实现的计算马氏距离算法示例
Python实现的计算马氏距离算法示例 本文实例讲述了Python实现的计算马氏距离算法.分享给大家供大家参考,具体如下: 我给写成函数调用了 python实现马氏距离源代码: # encod ...
- Levenshtein Distance莱文斯坦距离算法来计算字符串的相似度
Levenshtein Distance莱文斯坦距离定义: 数学上,两个字符串a.b之间的莱文斯坦距离表示为levab(|a|, |b|). levab(i, j) = max(i, j) 如果mi ...
随机推荐
- setAttribute一个兼容性问题
前几天工作中遇到一个js问题,本来js就不大会,倒腾了好长时间,并在做弹窗的时候用到了setAttribute,出现了不兼容的问题,在网上查了好多,真是郁闷,看来啥都得学啊. 主要的工作是做一个根据时 ...
- iOS 5.0 后UIViewController新增:willMoveToParentViewController和didMoveToParentViewCon
在iOS 5.0以前,我们在一个UIViewController中这样组织相关的UIView 在以前,一个UIViewController的View可能有很多小的子view.这些子view很多时候 ...
- Android画柱状图,圆形图和折线图的demo
效果图如下: demo下载地址:http://files.cnblogs.com/hsx514/wireframe.zip
- linux 安装SVN
1.环境centos6.4 2.安装svnyum -y install subversion 3.配置 建立版本库目录mkdir /www/svndata svnserve -d -r /www/sv ...
- every day english
job is in your freedom, not your compliance. through no fault of his own. as far as I understand you ...
- 自动抓取java堆栈
参数1 进程名字,参数2 最大线程数 例: pid为8888,达到1000个线程时自动抓取堆栈信息 ./autojstack.sh 8888 1000 & #!/bin/bashfileNam ...
- 【IDE】SharpDevelop
SharpDevelop 这个轻型的开发工具支持多种程序语言,包括C#.java以及VB.NET,同时还支持多种语言界面,象任何爱好者开发的工具一样.这个编辑器的界面风格类似于Office XP以及V ...
- shell 内网主机存活探测器
最近在学习shell 编程,闲来无事,搞了一个小shell. 可以用来 对一个网段的存活主机进行 探测. #!/bin/bash # #// #blog:www.cnblogs.com/outline ...
- JavaScript的function对象
我必须先说Java与JavaScript没有关系,不是我以前想的那个样子的(JavaScript是Java的一种超进化) 在JavaScript中,函数(function)就是对象. JavaScri ...
- nodejs 基本操作
查看nodejs版本 nodejs -v 升级nodejs node有一个模块叫n(这名字可够短的...),是专门用来管理node.js的版本的.首先安装n模块:npm install -g n 第二 ...