From aa30822af0b0da4c609728eab7269816b17c9922 Mon Sep 17 00:00:00 2001 From: marco <marco@5a81b35b-ba03-0410-adc8-b2c5c5119f08> Date: Thu, 11 Mar 2010 13:31:44 +0000 Subject: [PATCH] added recipe to load all pdb files in a directory git-svn-id: https://dng.biozentrum.unibas.ch/svn/openstructure/trunk@1808 5a81b35b-ba03-0410-adc8-b2c5c5119f08 --- website/raw/FAQ.mkdown | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/website/raw/FAQ.mkdown b/website/raw/FAQ.mkdown index dbd21bdec..735453586 100644 --- a/website/raw/FAQ.mkdown +++ b/website/raw/FAQ.mkdown @@ -2,8 +2,20 @@ title: FAQ - Frequently Answered Questions #FAQ - Frequently Answered Questions - 1. **Which licensing does Openstructure come with?** - Openstructure is released under GNU-LGPL license +**Which licensing does Openstructure come with?** + +Openstructure is released under GNU-LGPL license - * **Why another molecular Viewer?** - Openstructure is not aiming to be a Viewer, but more a molecular modelling platform, a toolkit. It features nice graphics, though! +**Why another molecular Viewer?** + +Openstructure is not aiming to be a Viewer, but more a molecular modelling platform, a toolkit. It features nice graphics, though! + +**How to I load all PDB files in a directory?** + +The python glob module can be used to match files in a certain directory against a glob pattern. Then use LoadPDB as you normally would. + + ::::python + import glob + pdbs=[] + for pdb_file in glob.glob(os.path.join(dir_path, '*.pdb')): + pdbs.append(io.LoadPDB(os.path.join(dir_path, pdb_file))) \ No newline at end of file -- GitLab