Giter Site home page Giter Site logo

james-kuo / fitting-network-models Goto Github PK

View Code? Open in Web Editor NEW
2.0 0.0 0.0 10.33 MB

Fitting and model checking a dynamic model for directed scale-free networks on a bitcoin network dataset.

R 100.00%
networks random-graphs power-laws degree-distribution preferential-attachment scale-free-networks network-statistics complex-networks complex-systems network-simulation

fitting-network-models's Introduction

Linear Preferential Attachment models are frequently used to theoretically explain why scale-free networks exist, or networks which have power-law as its degree distribution, but likelihood-based approaches are seldom done to test how well model explains data. I fitted such a model using a novel likelihood-based method developed in the literature on a bit-coin network in R and devised a set of heuristical and predictive checking simulation studies to examine how well model matches up with data. I developed the code from bottom-up for this project.

Final_Project.pdf is the paper. Kuo_Final_Presentation.pdf are the slides for an earlier version of the paper.

Functions.R, Analysis.R, and LinearAP.R are the main R codes which process the data, simulate the network, and estimate the model.

Bit.RData, SampleSim.RData, updated_graphs.RData and dynamics.RData are the processed datasets. soc-sign-bitcoinotc.csv is the raw dataset.

Some Pictures

Degree Distribution

A key aspect of the project is to see if degree distribution of the real network is well-captured by the model. The model hypothesized that both the in-degree and out-degree distributions of the real network will follow power law, meaning there will be a straight line in the log-log plot with a specified slope. Blue dots are what the degree distributions actually look like. Red dots are what the model predicts. A more rigorous statistical test (Kolmogorov-Smirnov test) shows the red and blue dots likely come from different distributions, so the model fails in this aspect.

A Picture of the Network

This is what the model says how the (scaled-down) bitcoin network should look like. Larger nodes have larger degrees (better connected).

fitting-network-models's People

Contributors

james-kuo avatar

Stargazers

 avatar  avatar

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.