Interpreting the C-Index Unicorn Meta Zoo #1: Why another podcast? Announcing the arrival of Valued Associate #679: Cesar Manara 2019 Moderator Election Q&A - Questionnaire 2019 Community Moderator Election ResultsEfficient dynamic clusteringDevices behavior in one continuous variable vs events rateCombining K-means clustering with Agglomerative clusteringSilhouette calculation in k-meansWhat is stored in heap structure in the following example?Clustering high dimensional datahow to compare different sets of time series dataDoes K-Means' objective function imply distance metric is EuclideanIs it possible to cluster data according to a target?clustering 2-dimensional euclidean vectors - appropriate dissimilarity measure
How to translate "red flag" into Spanish?
Implementing 3DES algorithm in Java: is my code secure?
How do I prove this combinatorial identity
Was Dennis Ritchie being too modest in this quote about C and Pascal?
Older movie/show about humans on derelict alien warship which refuels by passing through a star
Why didn't the Space Shuttle bounce back into space as many times as possible so as to lose a lot of kinetic energy up there?
Why do games have consumables?
Multiple fireplaces in an apartment building?
Contradiction proof for inequality of P and NP?
How do I check if a string is entirely made of the same substring?
Is there metaphorical meaning of "aus der Haft entlassen"?
Jaya, Venerated Firemage + Chandra's Pyrohelix = 4 damage among two targets?
My admission is revoked after accepting the admission offer
Raising a bilingual kid. When should we introduce the majority language?
"Rubric" as meaning "signature" or "personal mark" -- is this accepted usage?
Multiple options vs single option UI
A faster way to compute the largest prime factor
My bank got bought out, am I now going to have to start filing tax returns in a different state?
A strange hotel
Drawing a german abacus as in the books of Adam Ries
Why does Arg'[1. + I] return -0.5?
Long vowel quality before R
All ASCII characters with a given bit count
Does Feeblemind produce an ongoing magical effect that can be dispelled?
Interpreting the C-Index
Unicorn Meta Zoo #1: Why another podcast?
Announcing the arrival of Valued Associate #679: Cesar Manara
2019 Moderator Election Q&A - Questionnaire
2019 Community Moderator Election ResultsEfficient dynamic clusteringDevices behavior in one continuous variable vs events rateCombining K-means clustering with Agglomerative clusteringSilhouette calculation in k-meansWhat is stored in heap structure in the following example?Clustering high dimensional datahow to compare different sets of time series dataDoes K-Means' objective function imply distance metric is EuclideanIs it possible to cluster data according to a target?clustering 2-dimensional euclidean vectors - appropriate dissimilarity measure
$begingroup$
I have some problems understanding/interpreting the C-Index cluster quality measure. So, if we have
$c(x_i, x_j) = 1 $ if $ x_i, x_j $ in the same cluster; $0$ else
$Gamma = sum_ i=1^n-1sum_ j=i+1^n d(x_i,x_j)*c(x_i,x_j)$
$alpha = sum_ i=1^n-1sum_ j=i+1^n c(x_i,x_j)$
$min=$ sum of the $alpha$ smallest $d(x_i,x_j)$ of distinct pairs $x_i,x_j$ where $x_i neq x_j$
$max=$ sum of the $alpha$ largest $d(x_i,x_j)$ of distinct pairs $x_i,x_j$ where $x_i neq x_j$
then the C-Index is defined as $C=fracGamma - minmax - min$
The result is a value in $[0, 1]$, where lower values indicate a better cluster quality.
So, here are some things I get from this value:
- if all elements in a cluster are close together and all clusters are far apart, we can get $Gamma=min$, which means $C=0$
- Analogously, in a worst case scenario, all the observations that are furthers apart might be in the same cluster, so we would get $Gamma=max$, which means $C=1$
Now, these are the things I'm unsure about:
First: If we only have a single cluster in our clustering (e.g. k-Means for $k=1$), then $alpha$ is equal to the number of distinct pairs of observations, so $max=min$, which means $C=fracGamma - minmax - min = fracGamma - minmin - min = fracGamma - min0$ and we get a division by 0. A similar problem occurs if we have $N$ observations in $N$ different clusters, since $c$ is always $0$ in that case. So, is it correct to say that the C-Index can only be used for clusterings with $k$ many clusters where $1 < k < N$, for $N$ observations?
Second: Is it reasonable to say that the C-Index is agnostic to the number of clusters (e.g. the value of $k$ in k-Means)? For instance, we might have 5 observations $x_1...x_5$ close to each other, but each put into a separate cluster $C_1...C_5$. Then, we might have a clusters $C_6=x_6, x_7$ where $x_6, x_7$ are very close to each other but far apart from all other observations. In that case, $Gamma=d(x_6,x_7)$, $alpha=1$, $min=d(x_6,x_7)$, so $Gamma=min$, which means $C=0$. That is, we have the best possible C-Index-Value, even though, intuitively, it might have been better to put $x_1...x_5$ into a single cluster.
Lastly, this is more about k-Means: if we use normal k-Means (not global k-Means), are we always guaranteed to reach $C=0$, for an unbounded number of iterations? I can't seem to find an example that wouldn't result in this.
clustering k-means
$endgroup$
add a comment |
$begingroup$
I have some problems understanding/interpreting the C-Index cluster quality measure. So, if we have
$c(x_i, x_j) = 1 $ if $ x_i, x_j $ in the same cluster; $0$ else
$Gamma = sum_ i=1^n-1sum_ j=i+1^n d(x_i,x_j)*c(x_i,x_j)$
$alpha = sum_ i=1^n-1sum_ j=i+1^n c(x_i,x_j)$
$min=$ sum of the $alpha$ smallest $d(x_i,x_j)$ of distinct pairs $x_i,x_j$ where $x_i neq x_j$
$max=$ sum of the $alpha$ largest $d(x_i,x_j)$ of distinct pairs $x_i,x_j$ where $x_i neq x_j$
then the C-Index is defined as $C=fracGamma - minmax - min$
The result is a value in $[0, 1]$, where lower values indicate a better cluster quality.
So, here are some things I get from this value:
- if all elements in a cluster are close together and all clusters are far apart, we can get $Gamma=min$, which means $C=0$
- Analogously, in a worst case scenario, all the observations that are furthers apart might be in the same cluster, so we would get $Gamma=max$, which means $C=1$
Now, these are the things I'm unsure about:
First: If we only have a single cluster in our clustering (e.g. k-Means for $k=1$), then $alpha$ is equal to the number of distinct pairs of observations, so $max=min$, which means $C=fracGamma - minmax - min = fracGamma - minmin - min = fracGamma - min0$ and we get a division by 0. A similar problem occurs if we have $N$ observations in $N$ different clusters, since $c$ is always $0$ in that case. So, is it correct to say that the C-Index can only be used for clusterings with $k$ many clusters where $1 < k < N$, for $N$ observations?
Second: Is it reasonable to say that the C-Index is agnostic to the number of clusters (e.g. the value of $k$ in k-Means)? For instance, we might have 5 observations $x_1...x_5$ close to each other, but each put into a separate cluster $C_1...C_5$. Then, we might have a clusters $C_6=x_6, x_7$ where $x_6, x_7$ are very close to each other but far apart from all other observations. In that case, $Gamma=d(x_6,x_7)$, $alpha=1$, $min=d(x_6,x_7)$, so $Gamma=min$, which means $C=0$. That is, we have the best possible C-Index-Value, even though, intuitively, it might have been better to put $x_1...x_5$ into a single cluster.
Lastly, this is more about k-Means: if we use normal k-Means (not global k-Means), are we always guaranteed to reach $C=0$, for an unbounded number of iterations? I can't seem to find an example that wouldn't result in this.
clustering k-means
$endgroup$
add a comment |
$begingroup$
I have some problems understanding/interpreting the C-Index cluster quality measure. So, if we have
$c(x_i, x_j) = 1 $ if $ x_i, x_j $ in the same cluster; $0$ else
$Gamma = sum_ i=1^n-1sum_ j=i+1^n d(x_i,x_j)*c(x_i,x_j)$
$alpha = sum_ i=1^n-1sum_ j=i+1^n c(x_i,x_j)$
$min=$ sum of the $alpha$ smallest $d(x_i,x_j)$ of distinct pairs $x_i,x_j$ where $x_i neq x_j$
$max=$ sum of the $alpha$ largest $d(x_i,x_j)$ of distinct pairs $x_i,x_j$ where $x_i neq x_j$
then the C-Index is defined as $C=fracGamma - minmax - min$
The result is a value in $[0, 1]$, where lower values indicate a better cluster quality.
So, here are some things I get from this value:
- if all elements in a cluster are close together and all clusters are far apart, we can get $Gamma=min$, which means $C=0$
- Analogously, in a worst case scenario, all the observations that are furthers apart might be in the same cluster, so we would get $Gamma=max$, which means $C=1$
Now, these are the things I'm unsure about:
First: If we only have a single cluster in our clustering (e.g. k-Means for $k=1$), then $alpha$ is equal to the number of distinct pairs of observations, so $max=min$, which means $C=fracGamma - minmax - min = fracGamma - minmin - min = fracGamma - min0$ and we get a division by 0. A similar problem occurs if we have $N$ observations in $N$ different clusters, since $c$ is always $0$ in that case. So, is it correct to say that the C-Index can only be used for clusterings with $k$ many clusters where $1 < k < N$, for $N$ observations?
Second: Is it reasonable to say that the C-Index is agnostic to the number of clusters (e.g. the value of $k$ in k-Means)? For instance, we might have 5 observations $x_1...x_5$ close to each other, but each put into a separate cluster $C_1...C_5$. Then, we might have a clusters $C_6=x_6, x_7$ where $x_6, x_7$ are very close to each other but far apart from all other observations. In that case, $Gamma=d(x_6,x_7)$, $alpha=1$, $min=d(x_6,x_7)$, so $Gamma=min$, which means $C=0$. That is, we have the best possible C-Index-Value, even though, intuitively, it might have been better to put $x_1...x_5$ into a single cluster.
Lastly, this is more about k-Means: if we use normal k-Means (not global k-Means), are we always guaranteed to reach $C=0$, for an unbounded number of iterations? I can't seem to find an example that wouldn't result in this.
clustering k-means
$endgroup$
I have some problems understanding/interpreting the C-Index cluster quality measure. So, if we have
$c(x_i, x_j) = 1 $ if $ x_i, x_j $ in the same cluster; $0$ else
$Gamma = sum_ i=1^n-1sum_ j=i+1^n d(x_i,x_j)*c(x_i,x_j)$
$alpha = sum_ i=1^n-1sum_ j=i+1^n c(x_i,x_j)$
$min=$ sum of the $alpha$ smallest $d(x_i,x_j)$ of distinct pairs $x_i,x_j$ where $x_i neq x_j$
$max=$ sum of the $alpha$ largest $d(x_i,x_j)$ of distinct pairs $x_i,x_j$ where $x_i neq x_j$
then the C-Index is defined as $C=fracGamma - minmax - min$
The result is a value in $[0, 1]$, where lower values indicate a better cluster quality.
So, here are some things I get from this value:
- if all elements in a cluster are close together and all clusters are far apart, we can get $Gamma=min$, which means $C=0$
- Analogously, in a worst case scenario, all the observations that are furthers apart might be in the same cluster, so we would get $Gamma=max$, which means $C=1$
Now, these are the things I'm unsure about:
First: If we only have a single cluster in our clustering (e.g. k-Means for $k=1$), then $alpha$ is equal to the number of distinct pairs of observations, so $max=min$, which means $C=fracGamma - minmax - min = fracGamma - minmin - min = fracGamma - min0$ and we get a division by 0. A similar problem occurs if we have $N$ observations in $N$ different clusters, since $c$ is always $0$ in that case. So, is it correct to say that the C-Index can only be used for clusterings with $k$ many clusters where $1 < k < N$, for $N$ observations?
Second: Is it reasonable to say that the C-Index is agnostic to the number of clusters (e.g. the value of $k$ in k-Means)? For instance, we might have 5 observations $x_1...x_5$ close to each other, but each put into a separate cluster $C_1...C_5$. Then, we might have a clusters $C_6=x_6, x_7$ where $x_6, x_7$ are very close to each other but far apart from all other observations. In that case, $Gamma=d(x_6,x_7)$, $alpha=1$, $min=d(x_6,x_7)$, so $Gamma=min$, which means $C=0$. That is, we have the best possible C-Index-Value, even though, intuitively, it might have been better to put $x_1...x_5$ into a single cluster.
Lastly, this is more about k-Means: if we use normal k-Means (not global k-Means), are we always guaranteed to reach $C=0$, for an unbounded number of iterations? I can't seem to find an example that wouldn't result in this.
clustering k-means
clustering k-means
edited Mar 11 '18 at 19:18
Silas Berger
asked Mar 11 '18 at 16:42
Silas BergerSilas Berger
114
114
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
$begingroup$
For the first Q you already give a counterexample:
It is biased to k, it prefers k = N. And it will also overrate N-1, N-2, ... So it is not agnostic to k.
If k-means would always find the best C index, then the C index would just be redundant to SSQ, which is much cheaper to compute... But you probably have just been looking at way too simple toy datasets. Use real data.
$endgroup$
$begingroup$
Great, that makes sense, thanks for the answer! I still have some trouble picturing exactly how the C-Index can increase while the SSQ decreases (although I do work on a dataset where that happens), but I'll work on that ;-) Still, I don't quite see how it can prefer k = N. That would leave alpha=0, and if min and max are the alpha shortest/longest distances, that means max and min are 0, max-min=0, and we get a division by 0, right...?
$endgroup$
– Silas Berger
Mar 14 '18 at 7:43
$begingroup$
More precisely, you get 0/0, and in most cases (you'll need to check the math yourself for this particular case though) the proper substitute then is 0. Or intuitively: if the best case equals the worst case (max=min), then any solution is perfect (0). But what you need to consider is k almost n!
$endgroup$
– Anony-Mousse
Mar 14 '18 at 8:48
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "557"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdatascience.stackexchange.com%2fquestions%2f28942%2finterpreting-the-c-index%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
For the first Q you already give a counterexample:
It is biased to k, it prefers k = N. And it will also overrate N-1, N-2, ... So it is not agnostic to k.
If k-means would always find the best C index, then the C index would just be redundant to SSQ, which is much cheaper to compute... But you probably have just been looking at way too simple toy datasets. Use real data.
$endgroup$
$begingroup$
Great, that makes sense, thanks for the answer! I still have some trouble picturing exactly how the C-Index can increase while the SSQ decreases (although I do work on a dataset where that happens), but I'll work on that ;-) Still, I don't quite see how it can prefer k = N. That would leave alpha=0, and if min and max are the alpha shortest/longest distances, that means max and min are 0, max-min=0, and we get a division by 0, right...?
$endgroup$
– Silas Berger
Mar 14 '18 at 7:43
$begingroup$
More precisely, you get 0/0, and in most cases (you'll need to check the math yourself for this particular case though) the proper substitute then is 0. Or intuitively: if the best case equals the worst case (max=min), then any solution is perfect (0). But what you need to consider is k almost n!
$endgroup$
– Anony-Mousse
Mar 14 '18 at 8:48
add a comment |
$begingroup$
For the first Q you already give a counterexample:
It is biased to k, it prefers k = N. And it will also overrate N-1, N-2, ... So it is not agnostic to k.
If k-means would always find the best C index, then the C index would just be redundant to SSQ, which is much cheaper to compute... But you probably have just been looking at way too simple toy datasets. Use real data.
$endgroup$
$begingroup$
Great, that makes sense, thanks for the answer! I still have some trouble picturing exactly how the C-Index can increase while the SSQ decreases (although I do work on a dataset where that happens), but I'll work on that ;-) Still, I don't quite see how it can prefer k = N. That would leave alpha=0, and if min and max are the alpha shortest/longest distances, that means max and min are 0, max-min=0, and we get a division by 0, right...?
$endgroup$
– Silas Berger
Mar 14 '18 at 7:43
$begingroup$
More precisely, you get 0/0, and in most cases (you'll need to check the math yourself for this particular case though) the proper substitute then is 0. Or intuitively: if the best case equals the worst case (max=min), then any solution is perfect (0). But what you need to consider is k almost n!
$endgroup$
– Anony-Mousse
Mar 14 '18 at 8:48
add a comment |
$begingroup$
For the first Q you already give a counterexample:
It is biased to k, it prefers k = N. And it will also overrate N-1, N-2, ... So it is not agnostic to k.
If k-means would always find the best C index, then the C index would just be redundant to SSQ, which is much cheaper to compute... But you probably have just been looking at way too simple toy datasets. Use real data.
$endgroup$
For the first Q you already give a counterexample:
It is biased to k, it prefers k = N. And it will also overrate N-1, N-2, ... So it is not agnostic to k.
If k-means would always find the best C index, then the C index would just be redundant to SSQ, which is much cheaper to compute... But you probably have just been looking at way too simple toy datasets. Use real data.
answered Mar 13 '18 at 8:49
Anony-MousseAnony-Mousse
5,330625
5,330625
$begingroup$
Great, that makes sense, thanks for the answer! I still have some trouble picturing exactly how the C-Index can increase while the SSQ decreases (although I do work on a dataset where that happens), but I'll work on that ;-) Still, I don't quite see how it can prefer k = N. That would leave alpha=0, and if min and max are the alpha shortest/longest distances, that means max and min are 0, max-min=0, and we get a division by 0, right...?
$endgroup$
– Silas Berger
Mar 14 '18 at 7:43
$begingroup$
More precisely, you get 0/0, and in most cases (you'll need to check the math yourself for this particular case though) the proper substitute then is 0. Or intuitively: if the best case equals the worst case (max=min), then any solution is perfect (0). But what you need to consider is k almost n!
$endgroup$
– Anony-Mousse
Mar 14 '18 at 8:48
add a comment |
$begingroup$
Great, that makes sense, thanks for the answer! I still have some trouble picturing exactly how the C-Index can increase while the SSQ decreases (although I do work on a dataset where that happens), but I'll work on that ;-) Still, I don't quite see how it can prefer k = N. That would leave alpha=0, and if min and max are the alpha shortest/longest distances, that means max and min are 0, max-min=0, and we get a division by 0, right...?
$endgroup$
– Silas Berger
Mar 14 '18 at 7:43
$begingroup$
More precisely, you get 0/0, and in most cases (you'll need to check the math yourself for this particular case though) the proper substitute then is 0. Or intuitively: if the best case equals the worst case (max=min), then any solution is perfect (0). But what you need to consider is k almost n!
$endgroup$
– Anony-Mousse
Mar 14 '18 at 8:48
$begingroup$
Great, that makes sense, thanks for the answer! I still have some trouble picturing exactly how the C-Index can increase while the SSQ decreases (although I do work on a dataset where that happens), but I'll work on that ;-) Still, I don't quite see how it can prefer k = N. That would leave alpha=0, and if min and max are the alpha shortest/longest distances, that means max and min are 0, max-min=0, and we get a division by 0, right...?
$endgroup$
– Silas Berger
Mar 14 '18 at 7:43
$begingroup$
Great, that makes sense, thanks for the answer! I still have some trouble picturing exactly how the C-Index can increase while the SSQ decreases (although I do work on a dataset where that happens), but I'll work on that ;-) Still, I don't quite see how it can prefer k = N. That would leave alpha=0, and if min and max are the alpha shortest/longest distances, that means max and min are 0, max-min=0, and we get a division by 0, right...?
$endgroup$
– Silas Berger
Mar 14 '18 at 7:43
$begingroup$
More precisely, you get 0/0, and in most cases (you'll need to check the math yourself for this particular case though) the proper substitute then is 0. Or intuitively: if the best case equals the worst case (max=min), then any solution is perfect (0). But what you need to consider is k almost n!
$endgroup$
– Anony-Mousse
Mar 14 '18 at 8:48
$begingroup$
More precisely, you get 0/0, and in most cases (you'll need to check the math yourself for this particular case though) the proper substitute then is 0. Or intuitively: if the best case equals the worst case (max=min), then any solution is perfect (0). But what you need to consider is k almost n!
$endgroup$
– Anony-Mousse
Mar 14 '18 at 8:48
add a comment |
Thanks for contributing an answer to Data Science Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdatascience.stackexchange.com%2fquestions%2f28942%2finterpreting-the-c-index%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown