"trim"(pdbs, row.inds=NULL, col.inds=NULL, ...)
pdbs
as obtained from
function pdbaln
or read.fasta.pdb
; a xyz matrix
containing the cartesian coordinates of C-alpha atoms. pdbs$ali
matrix). pdbs$ali
matrix). Trim residues and/or filter out structures from a PDBs object.
Utility function to remove structures, or trim off columns, in a pdbs object.
Grant, B.J. et al. (2006) Bioinformatics 22, 2695--2696.
## Fetch PDB files and split to chain A only PDB files ids <- c("1a70_A", "1czp_A", "1frd_A", "1fxi_A", "1iue_A", "1pfd_A") raw.files <- get.pdb(ids, path = "raw_pdbs")Warning message: raw_pdbs/1a70.pdb exists. Skipping download Warning message: raw_pdbs/1czp.pdb exists. Skipping download Warning message: raw_pdbs/1frd.pdb exists. Skipping download Warning message: raw_pdbs/1fxi.pdb exists. Skipping download Warning message: raw_pdbs/1iue.pdb exists. Skipping download Warning message: raw_pdbs/1pfd.pdb exists. Skipping downloadfiles <- pdbsplit(raw.files, ids, path = "raw_pdbs/split_chain")|======================================================================| 100%## Sequence Alignement, and connectivity check pdbs <- pdbaln(files)Reading PDB files: raw_pdbs/split_chain/1a70_A.pdb raw_pdbs/split_chain/1czp_A.pdb raw_pdbs/split_chain/1frd_A.pdb raw_pdbs/split_chain/1fxi_A.pdb raw_pdbs/split_chain/1iue_A.pdb raw_pdbs/split_chain/1pfd_A.pdb . PDB has ALT records, taking A only, rm.alt=TRUE ..... Extracting sequences pdb/seq: 1 name: raw_pdbs/split_chain/1a70_A.pdb pdb/seq: 2 name: raw_pdbs/split_chain/1czp_A.pdb PDB has ALT records, taking A only, rm.alt=TRUE pdb/seq: 3 name: raw_pdbs/split_chain/1frd_A.pdb pdb/seq: 4 name: raw_pdbs/split_chain/1fxi_A.pdb pdb/seq: 5 name: raw_pdbs/split_chain/1iue_A.pdb pdb/seq: 6 name: raw_pdbs/split_chain/1pfd_A.pdbcons <- inspect.connectivity(pdbs) ## omit files with missing residues trim.pdbs(pdbs, row.inds=which(cons))1 . . . . 50 [Truncated_Name:1]1a70_A.pdb AAYKVTL--VTPTGNVEFQCPDDVYILDAAEEEGIDLPYSCRAGSCSSCA [Truncated_Name:2]1czp_A.pdb ATFKVTLINEAEGTKHEIEVPDDEYILDAAEEQGYDLPFSCRAGACSTCA [Truncated_Name:3]1frd_A.pdb ASYQVRLINKKQDIDTTIEIDEETTILDGAEENGIELPFSCHSGSCSSCV [Truncated_Name:4]1fxi_A.pdb ASYKVTL--KTPDGDNVITVPDDEYILDVAEEEGLDLPYSCRAGACSTCA [Truncated_Name:5]1iue_A.pdb AFYNITL--RTNDGEKKIECNEDEYILDASERQNVELPYSCRGGSCSTCA [Truncated_Name:6]1pfd_A.pdb ATYNVKL--ITPDGEVEFKCDDDVYVLDQAEEEGIDIPYSCRAGSCSSCA * ^ ^ * ^^ ^** * ^^*^**^ * **^* 1 . . . . 50 51 . . . . 100 [Truncated_Name:1]1a70_A.pdb GKLKTGSLNQDDQSFLDDDQIDEGWVLTCAAYPVSDVTIETHKKEELTA- [Truncated_Name:2]1czp_A.pdb GKLVSGTVDQSDQSFLDDDQIEAGYVLTCVAYPTSDVVIQTHKEEDLY-- [Truncated_Name:3]1frd_A.pdb GKVVEGEVDQSDQIFLDDEQMGKGFALLCVTYPRSNCTIKTHQEPYLA-- [Truncated_Name:4]1fxi_A.pdb GKLVSGPAPDEDQSFLDDDQIQAGYILTCVAYPTGDCVIETHKEEALY-- [Truncated_Name:5]1iue_A.pdb AKLVEGEVDNDDQSYLDEEQIKKKYILLCTCYPKSDCVIETHKEDELHDM [Truncated_Name:6]1pfd_A.pdb GKVVSGSIDQSDQSFLDDEQMDAGYVLTCHAYPTSDVVIETHKEEEIV-- ^*^ * ** ^**^^*^ ^ * * ** * ** ^ 51 . . . . 100 Call: trim.pdbs(pdbs = pdbs, row.inds = which(cons)) Class: pdbs, fasta Alignment dimensions: 6 sequence rows; 100 position columns (96 non-gap, 4 gap) + attr: id, xyz, resno, b, chain, ali, resid, sse, call