CoNet - Co-occurrence Network inference

News

CoNet - Documentation - Tutorial (HMP 16S phylotypes data subset)


The goal of this tutorial is to infer relationships between taxa at three vaginal sites (vaginal introitus, mid-vagina and posterior fornix) from 16S data collected by the HMP consortium.

Tutorial files
HMP 16S V35 phylotype data vaginal subset
metadata accompanying the vaginal subset, with lineages and bodysites
permutation settings file
bootstrap settings file
permutation distributions


This tutorial illustrates how to combine permutation and bootstrapping to compute method-specific p-values and consists of two parts: In the first part, we will generate a permutation score distribution file. In the second part, we generate bootstrap distributions. We compare these bootstrap distributions with the permutation distributions generated in the previous part and compute a method- and edge-specific p-value that combines both.



Permutation


You can skip the first part of the tutorial and download the permutation distributions available here.



Short version (using the CoNet permutations settings file)
  1. Open the CoNet plugin in Cytoscape and click the "Settings loading/saving" button.
  2. In the Settings menu, click "Select file" and browse the file tree to the permutation settings file.
  3. Click the "Apply settings in selected file" button and close the Settings menu.
  4. In the Data menu, click on the top-most "Select file" and browse the file tree to select the vaginal subset of the 16S HMP phylotype data.
  5. In the Data menu, click the "Metadata and features" button to open the metadata submenu.
  6. In the Metadata submenu, click the left "Select file" button and select the metadata file.
  7. Close the metadata and data menus and open the Randomization menu.
  8. In the Randomization menu, click the "Select folder" button and select a folder where you would like to save randomization results.
  9. Then specify the file name of the randomization result file.
  10. In the main menu, click the GO button.


Long version (entering everything manually in the CoNet interface)
  1. Open the CoNet plugin in Cytoscape and open the Data menu
  2. In the Data menu, click on the top-most "Select file" and browse the file tree to select the HMP 16S vaginal sub-set data file.
  3. Click the "Metadata and features" button to open the metadata submenu.
  4. In the Metadata submenu, click the left "Select file" button and select the metadata file.
  5. In the text area below, enter the metadata columns contained in the metadata file: lineage/taxon/bodysite
  6. In the text area for the group attribute, enter: bodysite
  7. In the text area for the lineage separator, enter: -
  8. Activate parent-child exclusion.
  9. Close the Metadata and Data menus and open the Methods menu.
  10. Select the following methods: Pearson, Spearman, Bray Curtis and Kullback-Leibler
  11. Open the submenu "Automatic threshold setting"
  12. Enter "50" as edge selection parameter and activate "Top and Bottom"
  13. Close the Methods menu and its threshold setting submenu and open the Merge menu.
  14. Activate option "multigraph"
  15. Close the Merge menu and open the Randomization menu
  16. Select the "edgeScores" routine and keep "shuffle_rows" as resampling method.
  17. Select "simes" as p-value merging method.
  18. Activate "Renormalize".
  19. Set the multiple test correction to "benjaminihochberg"
  20. Select 0.05 as lower p-value threshold
  21. In the "Save" box, push the "Select folder" button and select a folder where the randomization result will be stored.
  22. Then specify a file name for the randomization result in the text field below.
  23. Activate "Save randomizations to file".
  24. Close the randomization menu and open the configuration menu.
  25. Set the missing value treatment to "paiwise_omit"
  26. Set the minimum number of NaN-free value pairs to 50.
  27. In the main menu, click the GO button.

Bootstrap


Short version (using the CoNet bootstrap settings file)
  1. Open the CoNet plugin in Cytoscape and click the "Settings loading/saving" button.
  2. In the Settings menu, click "Select file" and browse the file tree to the bootstrap settings file.
  3. Click the "Apply settings in selected file" button and close the Settings menu.
  4. In the Data menu, click on the top-most "Select file" and browse the file tree to select the vaginal subset of the HMP 16S data.
  5. In the Data menu, click the "Metadata and features" button to open the metadata submenu.
  6. In the Metadata submenu, click the left "Select file" button and select the metadata file.
  7. Close the Data and Metadata menus and open the Randomization menu.
  8. In the Randomization menu, in the "Load null distributions" area, click "Open file" and browse the file tree to the permutation distribution file that you generated in the first part of this tutorial. If you skipped the first part, you can download it here.
  9. In the main menu, click the GO button.


Long version (entering everything manually in the CoNet interface, assuming you have configured CoNet for the permutation step)

The second part of the long version of this tutorial assumes that, even if you skipped the computation itself, you followed the configuration steps of the first part of the long version.


  1. Open the Randomization menu and un-check "Save randomizations to file"
  2. Empty the text field below "Select folder"
  3. In the "Load null distributions" area, click on "Open file" and select the file you generated with the first part of this tutorial. If you skipped the permutation step, download the permutation distributions here.
  4. Un-check "Renormalize"
  5. Select "bootstrap" as resampling method.
  6. Close the Randomization menu and open the Methods menu, there open the "Automatic threshold setting" menu.
  7. If you carried out the permutation step, empty the text field below the edge selection parameter to avoid repeating the threshold computation, else do not change the setting.
  8. In the main menu, click the GO button. The computation takes 1-2 minutes on a machine with 8GB RAM.

Result


The network returned by CoNet has no layout, as layout computation can be time-consuming, depending on the chosen algorithm. You can layout the network using one of Cytoscape's supported layouts, for instance the yFiles-layout Organic. You can then use the VizMapperTM to set body-site specific colors. After these processing steps, the network may look like the one shown below. Due to the low permutation and bootstrap iteration numbers, different results are possible.



You can save the current CoNet setting by clicking on the "Settings loading/saving" button in the main menu and then selecting a folder and typing a file name to which to save the current settings.