Giter Site home page Giter Site logo

johannesuhl / sequential_clustering_viz Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 3.2 MB

Effectively visualizing cluster flows and sizes for sequential cluster analyses using matplotlib.

Python 100.00%
sequential-data sequenctial-clustering birch clustering sankey-diagram longitudinal-data cross-sectional data-visualization

sequential_clustering_viz's Introduction

Visualizing sequential clustering results

java 8 and prio java 8  array review example

Various applications require cluster analysis applied to sequential or longitudinal data. While there are numerous approaches for sequential clustering, visual-analytical methods to illustrate clustering results are sparse. The script sequential_cluster_flows.py reads longitudinal data, and exemplarily generates clusters for each temporal cross-section of the data. The number of instances per cluster and per point in time, as well as the number of clusters transitioning between clusters in subsequent points in time are then visualized using a network-based visualization technique, based on matplotlib.

The data used for demonstration of the visualization are 19 demographic characteristics reported for approx. 200 countries, from 1950 to present, and projected up to the year 2100, in 5-year intervals (see United Nations 2019, https://population.un.org/wpp/Download/Files/1_Indicators%20(Standard)/CSV_FILES/WPP2019_Period_Indicators_Medium.csv). BIRCH clustering was used to derive the clusters (and number of clusters) for each cross-section, using a range of thresholds dictating the granlarity of the cluster sequences (i.e., 0.1,0.2,0.3):

java 8 and prio java 8  array review examplejava 8 and prio java 8  array review examplejava 8 and prio java 8  array review example

References:

United Nations, Department of Economic and Social Affairs, Population Division (2019). World Population Prospects 2019, Online Edition. Rev. 1. https://population.un.org/wpp/Download/Standard/CSV/

Zhang, T., Ramakrishnan, R., & Livny, M. (1996). BIRCH: an efficient data clustering method for very large databases. ACM sigmod record, 25(2), 103-114.

Cluster sequences for BIRCH threshold of 0.2 enlarged:

java 8 and prio java 8  array review example

sequential_clustering_viz's People

Contributors

johannesuhl avatar

Stargazers

 avatar

Watchers

 avatar  avatar

sequential_clustering_viz's Issues

ValueError: ndarray is not C-contiguous

Dear @johannesuhl , thanks for sharing your code! But there is an error 'ValueError: ndarray is not C-contiguous' when I ran the code

        clust =  Birch(branching_factor=50, n_clusters=None, threshold=thresh, compute_labels=True).fit(X)

how to solve it ?

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.