Contact Session #3
Brain network science: from theory to practice. Hubs, clubs, and modules.
Intended learning outcomes:
- Familiarize with concepts from graph theory and network science
- Consider methods to study network properties in the brain and what they mean
- Evaluate network science concepts within the scope of neuroscience and critically assess studies with graph-theoretical approaches.
Here is your pre-assignment for the next contact session.
Your task is to work with your project peer and fully test the Brain Connectivity Toolbox with Matlab. You might not yet know the meaning of each function you run, but that should not prevent you to just run the functions and just look at the output: this is the task.
Please note: if you would rather do the task in Python, please use one of the networks at point 2 below and the python package NetworkX https://networkx.github.io/examples.html and/or the faster alternative Graph-tool https://graph-tool.skewed.de/. You need to try to produce similar output as described for the Matlab code below.
- Go to https://sites.google.com/site/bctnet/Home and download the toolbox and make sure you can run it with Matlab (i.e. add it to the path)
- Pick one network to test from https://sites.google.com/site/bctnet/datasets: if you have a fast computer use one of the two networks with 600+ nodes. If you have a small computer, use the macaque network with 71 nodes. You can of course use more than one network if you want to.
- Write a matlab script that loads the network and runs each of the measures listed here https://sites.google.com/site/bctnet/measures/list. Each measure produces a different output. If the output is a scalar, just report the number. If the output is a vector you need to do three plots: 1) visualize the values as a 'stem' plot 2) visualize the histogram 'hist' distribution of the values and 3) visualize a boxplot. If the output is a matrix, use imagesc function to plot a heatmap (remember the colorbar). Submit all the plots and values as a single PDF file to your GIT account. Submit the Matlab code to your GIT account. Since the work is done in pairs, it is enough to upload it to one of the two GIT accounts. Remember, each figure needs a figure caption just like in a scientific article. The code should contain as many comments as needed to explain each step to a reader who will evaluate your work without running the code, the captions should be as informative as possible to be clear to a reader who will evaluate your work. Remember to label your axes:
Figure.1 – Source https://xkcd.com/833/
- Write a second matlab script that does visualizations of the network using the functions listed in https://sites.google.com/site/bctnet/visualization under "Visualization of networks in MATLAB" and "Visualization of matrices in MATLAB". Merge all the plots into a single PDF file and upload it your GIT account. Submit the matlab code to your GIT account. Remember, each figure needs a figure caption just like in a scientific article. Since the work is done in pairs, it is enough to upload it to one of the two accounts. The code should contain as many comments as needed to explain each step to a reader who will evaluate your work without running the code, the captions should be as informative as possible to be clear to a reader who will evaluate your work. Remember to label your axes (see xkcd above).
- Optional for those who want to go an extra step. You can store the network in Pajek format and try to visualize it with Pajek http://mrvar.fdv.uni-lj.si/pajek/ and/or with Gephi https://gephi.org/. You need to learn the tools yourself, but they are easy and fun to play with. Save the image/images into a PDF file with caption and upload to GIT.
- Optional for those who want to go even a further extra step. You can check the tutorial on how to plot the networks with connectome viewer: http://www.cmtk.org/viewer/documentation/users/tutorials/tut_matlabnet.html Save the image/images into a PDF file with caption and upload to GIT.
- Submit the result by emailing Enrico the link of the GIT repository with the PDF files and Matlab (or Python) code before the contact session begins on May 4th, we will review your code and PDFs in the group work during the contact session.
Note: If any of you are blocked in any of the steps above, you can only ask for help through the forum. If you do not have a computer that allows you to perform such computations, please contact Enrico directly and he will give you access to one of our fast computing servers.
Lecture slides and material
Slides and materials will be uploaded at the bottom of this page.
If you couldn't make it to the first contact session, please catch up with the others with the assignment here below.