{"id":8328,"date":"2020-03-27T13:53:38","date_gmt":"2020-03-27T12:53:38","guid":{"rendered":"https:\/\/complex-systems-ai.com\/?page_id=8328"},"modified":"2022-12-03T23:04:44","modified_gmt":"2022-12-03T22:04:44","slug":"mesures-de-distance-pour-les-attributs-de-type-mixte","status":"publish","type":"page","link":"https:\/\/complex-systems-ai.com\/en\/data-partitioning\/distance-measures-for-attributes-of-mixed-type\/","title":{"rendered":"Distance measurements for attributes of mixed type"},"content":{"rendered":"<div data-elementor-type=\"wp-page\" data-elementor-id=\"8328\" class=\"elementor elementor-8328\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-ad12866 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"ad12866\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-33 elementor-top-column elementor-element elementor-element-6dd5d9e\" data-id=\"6dd5d9e\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-b889704 elementor-align-justify elementor-widget elementor-widget-button\" data-id=\"b889704\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"button.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<div class=\"elementor-button-wrapper\">\n\t\t\t\t\t<a class=\"elementor-button elementor-button-link elementor-size-sm\" href=\"https:\/\/complex-systems-ai.com\/en\/data-partitioning\/\">\n\t\t\t\t\t\t<span class=\"elementor-button-content-wrapper\">\n\t\t\t\t\t\t\t\t\t<span class=\"elementor-button-text\">Data partitioning<\/span>\n\t\t\t\t\t<\/span>\n\t\t\t\t\t<\/a>\n\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t<div class=\"elementor-column elementor-col-33 elementor-top-column elementor-element elementor-element-7580281\" data-id=\"7580281\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-b1e8985 elementor-align-justify elementor-widget elementor-widget-button\" data-id=\"b1e8985\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"button.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<div class=\"elementor-button-wrapper\">\n\t\t\t\t\t<a class=\"elementor-button elementor-button-link elementor-size-sm\" href=\"https:\/\/complex-systems-ai.com\/en\/\">\n\t\t\t\t\t\t<span class=\"elementor-button-content-wrapper\">\n\t\t\t\t\t\t\t\t\t<span class=\"elementor-button-text\">Home page<\/span>\n\t\t\t\t\t<\/span>\n\t\t\t\t\t<\/a>\n\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t<div class=\"elementor-column elementor-col-33 elementor-top-column elementor-element elementor-element-f1e5ac8\" data-id=\"f1e5ac8\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-5a3d896 elementor-align-justify elementor-widget elementor-widget-button\" data-id=\"5a3d896\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"button.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<div class=\"elementor-button-wrapper\">\n\t\t\t\t\t<a class=\"elementor-button elementor-button-link elementor-size-sm\" href=\"https:\/\/towardsdatascience.com\/the-proper-way-of-handling-mixed-type-data-state-of-the-art-distance-metrics-505eda236400\" target=\"_blank\" rel=\"noopener\">\n\t\t\t\t\t\t<span class=\"elementor-button-content-wrapper\">\n\t\t\t\t\t\t\t\t\t<span class=\"elementor-button-text\">Wiki<\/span>\n\t\t\t\t\t<\/span>\n\t\t\t\t\t<\/a>\n\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-b5aa49 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"b5aa49\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-67155426\" data-id=\"67155426\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-7affae5b elementor-widget elementor-widget-text-editor\" data-id=\"7affae5b\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewbox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewbox=\"0 0 24 24\" version=\"1.2\" baseprofile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/complex-systems-ai.com\/en\/data-partitioning\/distance-measures-for-attributes-of-mixed-type\/#Mesures-de-distance-pour-les-attributs-de-type-mixte\" >Distance measurements for attributes of mixed type<\/a><\/li><\/ul><\/nav><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Mesures-de-distance-pour-les-attributs-de-type-mixte\"><\/span>Distance measurements for attributes of mixed type<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Many methods of <a href=\"https:\/\/complex-systems-ai.com\/en\/data-partitioning\/\">partitioning<\/a> use distance measures to determine the similarity or dissimilarity between any pair of objects (like Distance Measures for attributes of mixed type). It is common to denote the distance between two instances x_i and x_j as: d(x_i, x_j). A valid distance measure must be symmetric and obtains its minimum value (usually zero) in the case of identical vectors. The distance measure is called a metric distance measure if it also satisfies the following properties:<\/p>\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" class=\"alignnone\" src=\"https:\/\/complex-systems-ai.com\/wp-content\/uploads\/2020\/03\/mesure1.png\" alt=\"Distance measurements for attributes of mixed type\" width=\"389\" height=\"84\" title=\"\"><\/figure>\n\n<p>In cases where the instances are characterized by attributes of mixed type, one can calculate the distance by combining different methods. For example, when calculating the distance between instances i and j using a metric such as Euclidean distance, one can calculate the difference between the <a href=\"https:\/\/complex-systems-ai.com\/en\/data-partitioning\/distance-measures-for-nominal-attributes\/\">nominal attributes<\/a> and binary as 0s or 1s (\u201cmatch\u201d or \u201cmismatch\u201d, respectively), and the difference between the <a href=\"https:\/\/complex-systems-ai.com\/en\/data-partitioning\/minkowski-for-numeric-attributes\/\">numeric attributes<\/a> as the difference between their normalized values. The square of each of these differences will be added to the total distance. Such a calculation is used in many clustering algorithms.<\/p>\n\n<p>The dissimilarity d (x_i, x_j) between two instances, containing p attributes of mixed types, is defined as:<\/p>\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" class=\"alignnone\" src=\"https:\/\/complex-systems-ai.com\/wp-content\/uploads\/2020\/03\/mesure8.png\" alt=\"Distance measurements for attributes of mixed type\" width=\"208\" height=\"113\" title=\"\"><\/figure>\n\n<p>where the indicator \u03b4 = 0 if one of the values is missing. The contribution of attribute n to the distance between the two objects d ^ (n) is calculated according to its type.<\/p>\n\n<p>If the attribute is binary or categorical:<\/p>\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" class=\"alignnone\" src=\"https:\/\/complex-systems-ai.com\/wp-content\/uploads\/2020\/03\/mesure9.png\" alt=\"Distance measurements for attributes of mixed type\" width=\"235\" height=\"66\" title=\"\"><\/figure>\n\n<p>If the attribute has a continuous value (where h goes through all non-missing objects for attribute n):<\/p>\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8338\" src=\"https:\/\/complex-systems-ai.com\/wp-content\/uploads\/2020\/03\/mesure10-1.png?w=195\" alt=\"Distance measurements for attributes of mixed type\" width=\"195\" height=\"37\" title=\"\"><\/figure>\n\n<p>If the attribute is ordinal, the normalized values of the attribute are first calculated, then z_i, n is treated as a continuous value.<\/p>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<\/div>","protected":false},"excerpt":{"rendered":"<p>Data Partitioning Wiki Home Page Distance Measures for Mixed Type Attributes Many partitioning methods use distance measures... <\/p>","protected":false},"author":1,"featured_media":0,"parent":8271,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-8328","page","type-page","status-publish","hentry"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/pages\/8328","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/comments?post=8328"}],"version-history":[{"count":8,"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/pages\/8328\/revisions"}],"predecessor-version":[{"id":18979,"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/pages\/8328\/revisions\/18979"}],"up":[{"embeddable":true,"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/pages\/8271"}],"wp:attachment":[{"href":"https:\/\/complex-systems-ai.com\/en\/wp-json\/wp\/v2\/media?parent=8328"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}