Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Distance between two distributions

Subject: Distance between two distributions

From: Alex Zak

Date: 30 Jan, 2009 21:26:42

Message: 1 of 12

What is the best criteria to measure distance between two independent
normal distributions using Matlab??

Thanks.

Subject: Distance between two distributions

From: Matt

Date: 30 Jan, 2009 21:52:02

Message: 2 of 12

Alex Zak <zak.alex@gmail.com> wrote in message <e3eb7a25-0da9-4520-892e-678c2189d549@f40g2000pri.googlegroups.com>...
> What is the best criteria to measure distance between two independent
> normal distributions using Matlab??
>
> Thanks.

Why do you ask?

Subject: Distance between two distributions

From: Alex Zak

Date: 31 Jan, 2009 02:03:48

Message: 3 of 12

On Jan 30, 4:52=A0pm, "Matt " <x...@whatever.com> wrote:
> Alex Zak <zak.a...@gmail.com> wrote in message <e3eb7a25-0da9-4520-892e-6=
78c2189d...@f40g2000pri.googlegroups.com>...
> > What is the best criteria to measure distance between two independent
> > normal distributions using Matlab??
>
> > Thanks.
>
> Why do you ask?

I have two (or more) data sets normally distributed, I need to find a
criteria of distance between them I didnt find appropriate function
for measuring this distance , therefore I am asking...

Subject: Distance between two distributions

From: Roger Stafford

Date: 31 Jan, 2009 04:22:01

Message: 4 of 12

Alex Zak <zak.alex@gmail.com> wrote in message <e3eb7a25-0da9-4520-892e-678c2189d549@f40g2000pri.googlegroups.com>...
> What is the best criteria to measure distance between two independent
> normal distributions using Matlab??
>
> Thanks.

  You could mean many different things by "distance" here. For example, you might want to use the Lp distance for some p - that is, the p-th root of the mean of the p-th power of the absolute differences between the two densities. Or there are many other definitions of distances. Who is to say what is "best"? What would you like to use?

Roger Stafford

Subject: Distance between two distributions

From: Greg Heath

Date: 31 Jan, 2009 05:00:10

Message: 5 of 12

On Jan 30, 4:26 pm, Alex Zak <zak.a...@gmail.com> wrote:
> What is the best criteria to measure distance between two independent
> normal distributions using Matlab??
>
> Thanks.

1. Mahalanobis distance for linear classifiers is proportional to

(m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)

2. Bhattycharya (Bhattacharya?) distance for linear and quadratic
classifiers is proportional to

(m2-m1)' * ( ( inv(C1) + inv(C2) )/2 ) * (m2-m1)

See Devijver and Kittler (1981?) for a comprehensive discussion of
separability measures.

More info is available in comp.ai.neural-nets.

Hope this helps.

Greg

Subject: Distance between two distributions

From: Greg Heath

Date: 31 Jan, 2009 05:44:19

Message: 6 of 12

On Jan 31, 12:00=A0am, Greg Heath <he...@alumni.brown.edu> wrote:
> On Jan 30, 4:26 pm, Alex Zak <zak.a...@gmail.com> wrote:
>
> > What is the best criteria to measure distance between two independent
> > normal distributions using Matlab??
>
> > Thanks.
>
> 1. Mahalanobis distance for linear classifiers is proportional to
>
> (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
>
> 2. Bhattycharya (Bhattacharya?) distance for linear and quadratic
> classifiers is proportional to
>
> (m2-m1)' * ( ( inv(C1) + inv(C2) )/2 ) * (m2-m1)

BZZT!

Sorry, that is proportional to a term in the quadratic classifier
discriminant.

See http://en.wikipedia.org/wiki/Bhattacharyya_coefficient

which yields

(1/8) * (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)

+ (1/2) * ln( det(C) / sqrt( det(C1) * det(C2) )


> See Devijver and Kittler (1981?) for a comprehensive discussion of
> separability measures.
>
> More info is available in comp.ai.neural-nets.


Hope this helps.

Greg

Subject: Distance between two distributions

From: Peter Perkins

Date: 2 Feb, 2009 15:47:36

Message: 7 of 12

Alex Zak wrote:
> What is the best criteria to measure distance between two independent
> normal distributions using Matlab??

Alex, the answer to that is likely to depend on what you plan on using that distance for.

Subject: Distance between two distributions

From: Alex Zak

Date: 2 Feb, 2009 20:56:08

Message: 8 of 12

On Jan 31, 12:44=A0am, Greg Heath <he...@alumni.brown.edu> wrote:
> On Jan 31, 12:00=A0am, Greg Heath <he...@alumni.brown.edu> wrote:
>
> > On Jan 30, 4:26 pm,AlexZak<zak.a...@gmail.com> wrote:
>
> > > What is the best criteria to measure distance between two independent
> > > normal distributions using Matlab??
>
> > > Thanks.
>
> > 1. Mahalanobis distance for linear classifiers is proportional to
>
> > (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
>
> > 2. Bhattycharya (Bhattacharya?) distance for linear and quadratic
> > classifiers is proportional to
>
> > (m2-m1)' * ( ( inv(C1) + inv(C2) )/2 ) * (m2-m1)
>
> BZZT!
>
> Sorry, that is proportional to a term in the quadratic classifier
> discriminant.
>
> Seehttp://en.wikipedia.org/wiki/Bhattacharyya_coefficient
>
> which yields
>
> (1/8) * (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
>
> + (1/2) * ln( det(C) / sqrt( det(C1) * det(C2) )
>
> > See Devijver and Kittler (1981?) for a comprehensive discussion of
> > separability measures.
>
> > More info is available in comp.ai.neural-nets.
>
> Hope this helps.
>
> Greg

Thanks

Subject: Distance between two distributions

From: Fatih

Date: 14 Apr, 2009 13:29:01

Message: 9 of 12

Alex Zak <zak.alex@gmail.com> wrote in message <97162316-c571-47e3-a40d-5d7a0a94f88a@i24g2000prf.googlegroups.com>...
> On Jan 31, 12:44=A0am, Greg Heath <he...@alumni.brown.edu> wrote:
> > On Jan 31, 12:00=A0am, Greg Heath <he...@alumni.brown.edu> wrote:
> >
> > > On Jan 30, 4:26 pm,AlexZak<zak.a...@gmail.com> wrote:
> >
> > > > What is the best criteria to measure distance between two independent
> > > > normal distributions using Matlab??
> >
> > > > Thanks.
> >
> > > 1. Mahalanobis distance for linear classifiers is proportional to
> >
> > > (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
> >
> > > 2. Bhattycharya (Bhattacharya?) distance for linear and quadratic
> > > classifiers is proportional to
> >
> > > (m2-m1)' * ( ( inv(C1) + inv(C2) )/2 ) * (m2-m1)
> >
> > BZZT!
> >
> > Sorry, that is proportional to a term in the quadratic classifier
> > discriminant.
> >
> > Seehttp://en.wikipedia.org/wiki/Bhattacharyya_coefficient
> >
> > which yields
> >
> > (1/8) * (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
> >
> > + (1/2) * ln( det(C) / sqrt( det(C1) * det(C2) )
> >
> > > See Devijver and Kittler (1981?) for a comprehensive discussion of
> > > separability measures.
> >
> > > More info is available in comp.ai.neural-nets.
> >
> > Hope this helps.
> >
> > Greg
>
> Thanks

I also will use a distance metric between two distributions. But my problem is that these two distributions contain noise wihich is rayleigh distributed. So how can i adapt the distance metric to rayleigh?

Subject: Distance between two distributions

From: Greg Heath

Date: 15 Apr, 2009 20:07:23

Message: 10 of 12

On Apr 14, 9:29=A0am, "Fatih " <fatih.arslan....@gmail.com> wrote:
> Alex Zak <zak.a...@gmail.com> wrote in message <97162316-c571-47e3-a40d-5=
d7a0a94f...@i24g2000prf.googlegroups.com>...
> > On Jan 31, 12:44=3DA0am, Greg Heath <he...@alumni.brown.edu> wrote:
> > > On Jan 31, 12:00=3DA0am, Greg Heath <he...@alumni.brown.edu> wrote:
>
> > > > On Jan 30, 4:26 pm,AlexZak<zak.a...@gmail.com> wrote:
>
> > > > > What is the best criteria to measure distance between two indepen=
dent
> > > > > normal distributions using Matlab??
>
> > > > > Thanks.
>
> > > > 1. Mahalanobis distance for linear classifiers is proportional to
>
> > > > (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
>
> > > > 2. Bhattycharya (Bhattacharya?) distance for linear and quadratic
> > > > classifiers is proportional to
>
> > > > (m2-m1)' * ( ( inv(C1) + inv(C2) )/2 ) * (m2-m1)
>
> > > BZZT!
>
> > > Sorry, that is proportional to a term in the quadratic classifier
> > > discriminant.
>
> > > Seehttp://en.wikipedia.org/wiki/Bhattacharyya_coefficient
>
> > > which yields
>
> > > (1/8) * (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
>
> > > + (1/2) * ln( det(C) / sqrt( det(C1) * det(C2) )
>
> > > > See Devijver and Kittler (1981?) for a comprehensive discussion of
> > > > separability measures.
>
> > > > More info is available in comp.ai.neural-nets.
>
> > > Hope this helps.
>
> > > Greg
>
> > Thanks
>
> I also will use a distance metric between two distributions. But my probl=
em is that these two distributions contain noise wihich is rayleigh distrib=
uted. So how can i adapt the distance metric to rayleigh?- Hide quoted text=
 -
>
> - Show quoted text -

If you look at all of the separability measures listed
in Devijver et al. You will see that they are defined
in terms of integrals over the distribution functions.

Very few are available in closed form.

If the Rayleigh components are just additive noise at
a high SNR, I would still use the same measures.

You haven't said what you want to use this for.

Sometimes the equal error rate for linear two class
clasification is an acceptable measure of separability.

Hope this helps.

Greg

Subject: Distance between two distributions

From: Fatih

Date: 16 Apr, 2009 12:20:04

Message: 11 of 12

Greg Heath <heath@alumni.brown.edu> wrote in message <391f9c31-a49b-41a0-a4e5-3fc1975ecee1@o30g2000vbc.googlegroups.com>...
> On Apr 14, 9:29=A0am, "Fatih " <fatih.arslan....@gmail.com> wrote:
> > Alex Zak <zak.a...@gmail.com> wrote in message <97162316-c571-47e3-a40d-5=
> d7a0a94f...@i24g2000prf.googlegroups.com>...
> > > On Jan 31, 12:44=3DA0am, Greg Heath <he...@alumni.brown.edu> wrote:
> > > > On Jan 31, 12:00=3DA0am, Greg Heath <he...@alumni.brown.edu> wrote:
> >
> > > > > On Jan 30, 4:26 pm,AlexZak<zak.a...@gmail.com> wrote:
> >
> > > > > > What is the best criteria to measure distance between two indepen=
> dent
> > > > > > normal distributions using Matlab??
> >
> > > > > > Thanks.
> >
> > > > > 1. Mahalanobis distance for linear classifiers is proportional to
> >
> > > > > (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
> >
> > > > > 2. Bhattycharya (Bhattacharya?) distance for linear and quadratic
> > > > > classifiers is proportional to
> >
> > > > > (m2-m1)' * ( ( inv(C1) + inv(C2) )/2 ) * (m2-m1)
> >
> > > > BZZT!
> >
> > > > Sorry, that is proportional to a term in the quadratic classifier
> > > > discriminant.
> >
> > > > Seehttp://en.wikipedia.org/wiki/Bhattacharyya_coefficient
> >
> > > > which yields
> >
> > > > (1/8) * (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
> >
> > > > + (1/2) * ln( det(C) / sqrt( det(C1) * det(C2) )
> >
> > > > > See Devijver and Kittler (1981?) for a comprehensive discussion of
> > > > > separability measures.
> >
> > > > > More info is available in comp.ai.neural-nets.
> >
> > > > Hope this helps.
> >
> > > > Greg
> >
> > > Thanks
> >
> > I also will use a distance metric between two distributions. But my probl=
> em is that these two distributions contain noise wihich is rayleigh distrib=
> uted. So how can i adapt the distance metric to rayleigh?- Hide quoted text=
> -
> >
> > - Show quoted text -
>
> If you look at all of the separability measures listed
> in Devijver et al. You will see that they are defined
> in terms of integrals over the distribution functions.
>
> Very few are available in closed form.
>
> If the Rayleigh components are just additive noise at
> a high SNR, I would still use the same measures.
>
> You haven't said what you want to use this for.
>
> Sometimes the equal error rate for linear two class
> clasification is an acceptable measure of separability.
>
> Hope this helps.
>
> Greg

I will use this metric in order to exract some pre defined shapes from SAR images.
SAR images contain speckle noise, which is multiplicative. I can take the log transform of the image so that the multiplicative noise will be additive noise.

another problem is how to calculate SNR without the original image?( I just have noisy image...)

Subject: Distance between two distributions

From: Greg Heath

Date: 17 Apr, 2009 09:20:39

Message: 12 of 12

On Apr 16, 8:20=A0am, "Fatih " <fatih.arslan....@gmail.com> wrote:
> Greg Heath<he...@alumni.brown.edu> wrote in message <391f9c31-a49b-41a0-a=
4e5-3fc1975ec...@o30g2000vbc.googlegroups.com>...
> > On Apr 14, 9:29=3DA0am, "Fatih " <fatih.arslan....@gmail.com> wrote:
> > > Alex Zak <zak.a...@gmail.com> wrote in message <97162316-c571-47e3-a4=
0d-5=3D
> > d7a0a94f...@i24g2000prf.googlegroups.com>...
> > > > On Jan 31, 12:44=3D3DA0am,Greg Heath<he...@alumni.brown.edu> wrote:
> > > > > On Jan 31, 12:00=3D3DA0am,Greg Heath<he...@alumni.brown.edu> wrot=
e:
>
> > > > > > On Jan 30, 4:26 pm,AlexZak<zak.a...@gmail.com> wrote:
>
> > > > > > > What is the best criteria to measure distance between two ind=
epen=3D
> > dent
> > > > > > > normal distributions using Matlab??
>
> > > > > > > Thanks.
>
> > > > > > 1. Mahalanobis distance for linear classifiers is proportional =
to
>
> > > > > > (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
>
> > > > > > 2. Bhattycharya (Bhattacharya?) distance for linear and quadrat=
ic
> > > > > > classifiers is proportional to
>
> > > > > > (m2-m1)' * ( ( inv(C1) + inv(C2) )/2 ) * (m2-m1)
>
> > > > > BZZT!
>
> > > > > Sorry, that is proportional to a term in the quadratic classifier
> > > > > discriminant.
>
> > > > > Seehttp://en.wikipedia.org/wiki/Bhattacharyya_coefficient
>
> > > > > which yields
>
> > > > > (1/8) * (m2-m1)' * inv( (C1 + C2)/2 ) * (m2-m1)
>
> > > > > + (1/2) * ln( det(C) / sqrt( det(C1) * det(C2) )
>
> > > > > > See Devijver and Kittler (1981?) for a comprehensive discussion=
 of
> > > > > > separability measures.
>
> > > > > > More info is available in comp.ai.neural-nets.
>
> > > > > Hope this helps.
>
> > > > > Greg
>
> > > > Thanks
>
> > > I also will use a distance metric between two distributions. But my p=
robl=3D
> > em is that these two distributions contain noise wihich is rayleigh dis=
trib=3D
> > uted. So how can i adapt the distance metric to rayleigh?- Hide quoted =
text=3D
> > =A0-
>
> > > - Show quoted text -
>
> > If you look at all of the separability measures listed
> > in Devijver et al. You will see that they are defined
> > in terms of integrals over the distribution functions.
>
> > Very few are available in closed form.
>
> > If the Rayleigh components are just additive noise at
> > a high SNR, I would still use the same measures.
>
> > You haven't said what you want to use this for.
>
> > Sometimes the equal error rate for linear two class
> > clasification is an acceptable measure of separability.
>
> > Hope this helps.
>
> > Greg
>
> I will use this metric in order to exract some pre defined shapes from SA=
R images. =A0
> SAR images contain speckle noise, which is multiplicative. I can take the=
 log transform of the image so that the multiplicative noise will be additi=
ve noise.
>
> another problem is how to calculate SNR without the original image?( I ju=
st have noisy image

I would try to estimate it with a low pass filter.

Hope this helps.

Greg

Tags for this Thread

No tags are associated with this thread.

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us