zoukankan      html  css  js  c++  java
  • matlab计算马氏平方距离

    马氏距离计算一个点到一个参考分布的距离。马氏距离的优点是不受各个维度特征尺度的影响(尺度无关)。

    d2 = mahal(Y, X)

    d2 = mahal(Y,X) returns the squared Mahalanobis distance of each observation in Y to the reference samples in X.

    返回Y中每个点相对于参考分布X的马氏平方距离。即Y_i与分布p(mu, cov)的距离,这里mu, cov通过X进行估计。

    The Mahalanobis distance is a measure between a sample point and a distribution.

    The Mahalanobis distance from a vector y to a distribution with mean μ and covariance Σ is

    This distance represents how far y is from the mean in number of standard deviations.

    mahal returns the squared Mahalanobis distance d2 from an observation in Y to the reference samples in X. In the mahal function, μ and Σ are the sample mean and covariance of the reference samples, respectively.

    因此,计算一个向量中各点(或向量)到自身分布的马氏平方距离表示为:

    d2 = mahal(X, X)
    

    计算一个向量中各点(或向量)到另一个参考分布的马氏平方距离表示为:

    d2 = mahal(Y, X)
    

      

     

     

     

    快去成为你想要的样子!
  • 相关阅读:
    C# 2.0 中Iterators的改进与实现原理浅析
    C#窗口关闭时最小化到托盘
    设计模式有趣解释
    序列化学习
    线程学习
    正则表达式
    .net内存回收与Dispose﹐Close﹐Finalize方法 [摘]
    5.匿名函数lambda
    2dns服务器解析创建
    2.ftp匿名
  • 原文地址:https://www.cnblogs.com/jiangkejie/p/15209045.html
Copyright © 2011-2022 走看看