Home > FR3DSource > zGetPDBInfo.m

zGetPDBInfo

PURPOSE ^

zGetPDBInfo(File) reads a data file about PDB files and extracts

SYNOPSIS ^

function [File] = zGetPDBInfo(File)

DESCRIPTION ^

 zGetPDBInfo(File) reads a data file about PDB files and extracts
 information about the current molecule stored in File

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 % zGetPDBInfo(File) reads a data file about PDB files and extracts
0002 % information about the current molecule stored in File
0003 
0004 % It uses PDBInfo.mat, which needs to be updated whenver new PDB data is
0005 % downloaded from NDB/PDB
0006 
0007 function [File] = zGetPDBInfo(File)
0008 
0009 load(['FR3DSource' filesep 'PDBInfo.mat'],'n','t','-mat');
0010 
0011 PDBNames = lower(t(:,1));              % convert PDB filenames to lowercase
0012 
0013 % i = strmatch(lower(File.Filename),PDBNames);
0014 
0015 i = find(ismember(PDBNames, lower(File.Filename)));
0016 
0017 if ~isempty(i),
0018   File.Info.Resolution  = n(i(1),1);
0019   File.Info.Descriptor  = t{i(1),2};
0020   File.Info.ExpTechnique= t{i(1),3};
0021   File.Info.ReleaseDate = t{i(1),4};
0022   File.Info.Author      = t{i(1),5};
0023   File.Info.Keywords    = t{i(1),6};
0024   File.Info.Source      = t{i(1),8};
0025 
0026   if ((n(i(1),2) ~= length(File.NT)) || isempty(t{i(1),9}) || n(i(1),3) == 0) && (length(File.NT) > 0) ,
0027     E  = abs(triu(File.Edge));
0028     n(i(1),3) = full(sum(sum((E > 0) .* (E < 16)))); % number of pairs
0029     n(i(1),2) = length(File.NT);
0030     t{i(1),9} = cat(2,File.NT.Base);
0031     save(['FR3DSource' filesep 'PDBInfo.mat'],'n','t'); % Matlab version 7
0032   end
0033 
0034 else
0035   File.Info.Resolution  = [];
0036   File.Info.Descriptor  = '';
0037   File.Info.ExpTechnique= '';
0038   File.Info.ReleaseDate = '';
0039   File.Info.Author      = '';
0040   File.Info.Keywords    = '';
0041   File.Info.Source      = '';
0042 end
0043

Generated on Fri 03-Apr-2009 09:52:35 by m2html © 2003