PDB write & Molviewer give dimensional error
조회 수: 10 (최근 30일)
이전 댓글 표시
Hi everyone!
I try to alter and superimpose multiple pdb files. I read the file with pdbread and can also transform it with e.g. pbd transform. But when I try to use either molviewer to look at the alterations (or the original read file) or try to save it with pdbwrite I get the error 'Dimensions of arrays being concatenated are not consistent.'
Because this also happens with unmodified pdb files, is there anything I am doing wrong with the reading? Or do I have to alter the MATLAB-Generated file before saving/viewing is possible?
Your help is really appreciated.
My very simple test code:
%read file
a=pdbread('C:\Users\zechmeisterin\Desktop\4d5q.pdb'); %PDB file downloaded directly from PDB website
pdbwrite('C:\Users\zechmeisterin\Desktop\modified4d5q.pdb',a); %save original
molviewer(a)
transf.T = eye(3); transf.b = 1; transf.c = [11.8 -2.8 -32.3]; % test transformation from mathworks
pdbtx = pdbtransform(a, transf, 'segment', 'all');
pdbwrite('C:\Users\zechmeisterin\Desktop\modified4d5q.pdb',pdbtx); %save modified
Error for molviewer:
Error using molviewer (line 161)
Encountered error while reading the PDB structure.
Dimensions of arrays being concatenated are not consistent.
Error for pdb write:
Error using horzcat
Dimensions of arrays being concatenated are not consistent.
Error in pdbwrite>writeCaveat (line 404)
z(2:end,12:lineLen+19) = [ repmat(mRec.idCode,noOfLines-1,1) ' '...
Error in pdbwrite>getPDBRecord (line 139)
pdbout = [pdbout;writeCaveat(pdb_struct.Caveat)];
Error in pdbwrite (line 97)
pdbrecord = getPDBRecord(pdbstruct);
Error in PDB_file_generator (line 3)
pdbwrite('C:\Users\zechmeisterin\Desktop\modified4d5q.pdb',a); %save original
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!