A python script that parses the SNAP facebook dataset into a single NetworkX network
Python
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
data initial Jun 10, 2014
.gitignore
README.org fixed typo in readme Feb 24, 2016
__init__.py fixed pathing issues Jun 11, 2014
facebook.py keep track of ego nodes Feb 24, 2016
facebook_combined.txt initial Jun 10, 2014
feature_map.txt initial Jun 10, 2014
hairball.pdf
readme-Ego.txt initial Jun 10, 2014

README.org

This is python script that parses the SNAP facebook dataset into a single NetworkX network.

Usage:

import facebook

# load the network
facebook.load_network()

print facebook.network.order()
print facebook.network.size()

# Look at a node's features
print facebook.network.node[0]['features']

# 0: feature not present for this user
# 1: user does not have this feature
# 2: user does have this feature

# look at the features of the whole network
print facebook.feature_matrix()

Tests:

./facebook.py