Protein Structure Network Layout

Usage

layout.cna(x, pdb, renumber=TRUE, k=2, full=FALSE)

Arguments

x
A protein structure network object as obtained from the ‘cna’ function.
pdb
A pdb class object as obtained from the ‘read.pdb’ function.
renumber
Logical, if TRUE the input ‘pdb’ will be re-numbered starting at residue number one before community coordinate averages are calculated.
k
A single element numeric vector between 1 and 3 specifying the returned coordinate dimensions.
full
Logical, if TRUE the full all-Calpha atom network coordinates will be returned rather than the default clustered network community coordinates.

Description

Determine protein structure network layout in 2D and 3D from the geometric center of each community.

Details

This function calculates the geometric center for each community from the atomic position of it's Calpha atoms taken from a corresponding PDB file. Care needs to be taken to ensure the PDB residue numbers and the community vector names/length match.

The community residue membership are typically taken from the input network object but can be supplied as a list object with 'x$communities$membership'.

Value

A numeric matrix of Nxk, where N is the number of communities and k the number of dimensions requested.

Examples

# Load the correlation network attach(hivp) # Read the starting PDB file to determine atom correspondence pdbfile <- system.file("examples/hivp.pdb", package="bio3d") pdb <- read.pdb(pdbfile) # Plot will be slow #xy <- plot.cna(net) #plot3d.cna(net, pdb) layout.cna(net, pdb, k=3)
[,1] [,2] [,3] [1,] 54.20721 51.78683 -0.283875 [2,] 41.19425 55.71650 1.703250 [3,] 44.24055 51.83473 -15.342545 [4,] 46.52750 45.66275 -2.527750 [5,] 47.13800 39.66150 -4.226500 [6,] 41.07753 37.62945 -14.454408 [7,] 47.28200 43.16800 -6.872000 [8,] 50.95400 42.68200 -6.044000 [9,] 51.68650 42.70700 -10.158000 [10,] 54.76550 47.29200 -9.860750 [11,] 52.06730 44.91635 14.223000 [12,] 37.94462 40.84714 15.046220 [13,] 45.66275 46.52750 2.527750 [14,] 39.66150 47.13800 4.226500 [15,] 45.63000 45.40700 9.031000 [16,] 42.92500 49.11800 6.458000 [17,] 42.70700 51.68650 10.158000 [18,] 47.29200 54.76550 9.860750
layout.cna(net, pdb)
[,1] [,2] [1,] -0.9244384 -8.8471084 [2,] 3.8885314 -4.4294924 [3,] -13.8356282 -3.7422487 [4,] -2.8404262 0.4926773 [5,] -5.6168478 4.9550221 [6,] -14.8590220 9.6928844 [7,] -7.6106804 1.9063132 [8,] -7.5147240 0.2103874 [9,] -11.6278838 -0.4053747 [10,] -11.0810081 -5.9091380 [11,] 12.3469897 -1.4097715 [12,] 14.8544892 10.1150636 [13,] 2.3607940 0.4997270 [14,] 5.1346768 3.5481359 [15,] 8.4868652 1.7018172 [16,] 7.0830006 0.1392125 [17,] 11.1492891 -1.6719364 [18,] 10.6060227 -6.8461708
# can be used as input to plot.cna and plot3d.cna.... # plot.cna( net, layout=layout.cna(net, pdb) ) # plot3d.cna(net, pdb, layout=layout.cna(net, pdb, k=3)) detach(hivp)

See also

plot.cna, plot.communities, igraph.plotting, plot.igraph

Author

Guido Scarabelli and Barry Grant