Error using pdbread (line 78)

1 view (last 30 days)
eli manasherov
eli manasherov on 23 Feb 2020
Edited: Walter Roberson on 23 Feb 2020
hello there
i write a function according to this:
A. Write a function for selecting and reading a pdb file.
i (The function does not receive input.
ii (Output: Structure with fields corresponding to pdb format.
iii (The function works as follows:
(1 (Asking the user to select a file (uigetfile command with output of file name and folder name).
(2 (composes the full name of the file (including path space on disk) and reads it the output argument of the function.
the function is like this:
function kovetz= A()
[choseK,choseD]=uigetfile('*.ent','shemkovetz');
kovetz=pdbread([choseK,choseD,]);
end
but i have an error that says
Error using pdbread (line 78)
File does not exist or does not contain valid PDB data.
Error in A (line 3)
kovetz=pdbread([choseK,choseD,]);
What can I do to fix it??

Accepted Answer

Walter Roberson
Walter Roberson on 23 Feb 2020
Edited: Walter Roberson on 23 Feb 2020
kovetz = pdbread(fullfile(choseD,choseK));

More Answers (0)

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!