GithubHelp home page GithubHelp logo

Comments (2)

danyaljj avatar danyaljj commented on June 9, 2024

Here is a slightly older version of the file, probably right before losing the outer loop.

clear all; close all; clc;
pathAll('');
rate = 0.01;
 
for iii = 1:5
    rate = 0.03; 
    p = 1;   
    for k_variance = -3:3
    %for rate = [0.01 0.03 0.05]
        %for p = [0.8 0.9 0.95 1]
            %     p = 1;
            if rate == 0.01 && iii == 1
                continue;   
            end
 
            [X,Y] = readUCIData('iris' );
            %[X,Y] = gaussians(200);
            size1 = size(X,1);
            order = randperm(size1);
            X = X(order,:);
            Y = Y(order,:);
            k = 3;
            kprime = k-k_variance;
            if kprime > 0 
                experiment_1(X,Y,kprime, ['Variable_k_iris_p=' num2str(p) .... 
                    '_rate=' num2str(rate) '_i=' num2str(iii) '_k_variance='  num2str(k_variance) ], rate, p);
            end
            %     p = 1;
            [X,Y] = readUCIData('wine');
            %[X,Y] = gaussians(200);
            size1 = size(X,1);
            order = randperm(size1);
            X = X(order,:);
            Y = Y(order,:);
            k = 3;
            kprime = k-k_variance;
            if kprime > 0 
                experiment_1(X,Y,kprime, ['Variable_k_wine_p=' num2str(p) '_rate=' num2str(rate) '_i=' num2str(iii)], rate, p);                
            end
 
            %     p = 1;
            [X,Y] = readUCIData('ecoli');
            %[X,Y] = gaussians(200);
            size1 = size(X,1);
            order = randperm(size1);
            X = X(order,:);
            Y = Y(order,:);
            k = 8;
            kprime = k-k_variance;
            if kprime > 0 
                experiment_1(X,Y,kprime, ['Variable_k_eclli_p=' num2str(p) '_rate=' num2str(rate) '_i=' num2str(iii)], rate, p);
            end
 
            %     p = 1;
            [X,Y] = readUCIData('glass');
            %[X,Y] = gaussians(200);
            size1 = size(X,1);
            order = randperm(size1);
            X = X(order,:);
            Y = Y(order,:);
            k = 7;
            kprime = k-k_variance;
            if kprime > 0 
                experiment_1(X,Y,kprime, ['Variable_k_glass_p=' num2str(p) '_rate=' num2str(rate) '_i=' num2str(iii) ], rate, p);
            end
 
            %     p = 1;
            [X,Y] = readUCIData('isomosphere');
            %[X,Y] = gaussians(200);
            size1 = size(X,1);
            order = randperm(size1);
            X = X(order,:);
            Y = Y(order,:);
            k = 2;
            kprime = k-k_variance;
            if kprime > 0 
                experiment_1(X,Y,kprime, ['Variable_k_isomosphere_p=' num2str(p) '_rate=' num2str(rate) '_i=' num2str(iii)], rate, p);
            end
 
            %     p = 1;
            [X,Y] = readUCIData('balance');
            %[X,Y] = gaussians(200);
            size1 = size(X,1);
            order = randperm(size1);
            X = X(order,:);
            Y = Y(order,:);
            k = 3;
            kprime = k-k_variance;
            if kprime > 0 
                experiment_1(X,Y,kprime, ['Variable_k_balance_p=' num2str(p) '_rate=' num2str(rate) '_i=' num2str(iii)], rate, p);
            end
    end
end

from constrained_clustering.

se4u avatar se4u commented on June 9, 2024

Ah okay so k_variance is just the range of values of k that we are going to try, and iii is just the number of trials.

from constrained_clustering.

Related Issues (3)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.