>for (code, code, atomfile, chain) in (('1SHWA','1SHXA','1SHX','A'), > (pdbfile,pdbfile,fileName,'A')): > mdl = model(env, file=atomfile, model_segment=('FIRST:'+chain, 'LAST:'+chain)) > aln.append_model(mdl, atom_files=code, align_codes=atomfile)
it's python question, not modeller. your for-cycle executes 2 times, in first run code=1SHWA, then code=1SHXA, atomfile=1SHX, chan=A and body of for-cycle executed, in second run code=pdbfile, atomfile=fileName,chain=A. if you have variables pdbfile and fileName as strings defined, the body of for-cycle will be executed again. it seems, this is not that you supposed. maybe, something like this
atomfile='1SHX' for (code,chain) in (('1SHWA','A'),('1SHXA','A')): mdl = model(env, file=atomfile, model_segment=('FIRST:'+chain, 'LAST:'+chain)) aln.append_model(mdl, atom_files=code, align_codes=atomfile)
kind regards, Igor
modeller_usage-request@salilab.org пишет: > Send modeller_usage mailing list submissions to > modeller_usage@salilab.org > > To subscribe or unsubscribe via the World Wide Web, visit > https://salilab.org/mailman/listinfo/modeller_usage > or, via email, send a message with subject or body 'help' to > modeller_usage-request@salilab.org > > You can reach the person managing the list at > modeller_usage-owner@salilab.org > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of modeller_usage digest..." > > > Today's Topics: > > 1. Re: What is the mistake in this set of lines? (Ashish Runthala) > 2. Re: What is the mistake in this set of lines? (Ashish Runthala) > 3. Build a model with multiple models (junior) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Sat, 29 Oct 2011 10:39:22 +0530 (IST) > From: Ashish Runthala ashishr@bits-pilani.ac.in > Subject: Re: [modeller_usage] What is the mistake in this set of > lines? > To: modeller modeller_usage@salilab.org > Message-ID: > 20822758.298281319864962852.JavaMail.root@mailserver.bits-pilani.ac.in > > Content-Type: text/plain; charset=utf-8 > > Is it possible that i can declare some variables in python similar to the standard default MODELLER variables atomfile, pdbfile and code. > How these variables are declared in MODELLER? > > Thanks > Ashish > > Ashish Runthala, > Lecturer, Structural Biology Cell, > Biological Sciences Group, > BITS, Pilani > Rajasthan, INDIA > > ----- Original Message ----- > From: "Ashish Runthala" ashishr@bits-pilani.ac.in > To: "modeller" modeller_usage@salilab.org > Sent: Friday, October 28, 2011 8:17:00 AM GMT +05:30 Chennai, Kolkata, Mumbai, New Delhi > Subject: What is the mistake in this set of lines? > > Dear Modellers, > I wrote a script to do three template modeling for a target sequence from all the templates present in the same folder. > The script is expected to take 1SHW, 1SHX fixed and the third one should be iteratively taken from the current folder. > > MODELLER defines atom as any PDB or .atm template file and pdbfile is the keyword defined for template with chain ID. > So when i use pdbfile for both 1SHW, 1SHX why it only takes the one with the 2nd entry. Like a normal variable initial template name changes when it is assigned to some other template. > > So what is the mistake in this set of lines? How should i solve this task. > > for (code, code, atomfile, chain) in (('1SHWA','1SHXA','1SHX','A'), > (pdbfile,pdbfile,fileName,'A')): > mdl = model(env, file=atomfile, model_segment=('FIRST:'+chain, 'LAST:'+chain)) > aln.append_model(mdl, atom_files=code, align_codes=atomfile) > > > > Thanks, > Ashish > > > > Ashish Runthala, > Lecturer, Structural Biology Cell, > Biological Sciences Group, > BITS, Pilani > Rajasthan, INDIA > > > ------------------------------ > > Message: 2 > Date: Sun, 30 Oct 2011 15:52:37 +0530 (IST) > From: Ashish Runthala ashishr@bits-pilani.ac.in > Subject: Re: [modeller_usage] What is the mistake in this set of > lines? > To: modeller modeller_usage@salilab.org > Message-ID: > 15487763.309941319970157647.JavaMail.root@mailserver.bits-pilani.ac.in > > Content-Type: text/plain; charset=utf-8 > > What nobody knows to declare such data types? Any guesses with anyone what it should be, as probably there in MODELLER modules and functional binaries. > > > Ashish Runthala, > Lecturer, Structural Biology Cell, > Biological Sciences Group, > BITS, Pilani > Rajasthan, INDIA > > ----- Original Message ----- > From: "Ashish Runthala" ashishr@bits-pilani.ac.in > To: "modeller" modeller_usage@salilab.org > Sent: Saturday, October 29, 2011 10:39:22 AM GMT +05:30 Chennai, Kolkata, Mumbai, New Delhi > Subject: Re: What is the mistake in this set of lines? > > Is it possible that i can declare some variables in python similar to the standard default MODELLER variables atomfile, pdbfile and code. > How these variables are declared in MODELLER? > > Thanks > Ashish > > Ashish Runthala, > Lecturer, Structural Biology Cell, > Biological Sciences Group, > BITS, Pilani > Rajasthan, INDIA > > ----- Original Message ----- > From: "Ashish Runthala" ashishr@bits-pilani.ac.in > To: "modeller" modeller_usage@salilab.org > Sent: Friday, October 28, 2011 8:17:00 AM GMT +05:30 Chennai, Kolkata, Mumbai, New Delhi > Subject: What is the mistake in this set of lines? > > Dear Modellers, > I wrote a script to do three template modeling for a target sequence from all the templates present in the same folder. > The script is expected to take 1SHW, 1SHX fixed and the third one should be iteratively taken from the current folder. > > MODELLER defines atom as any PDB or .atm template file and pdbfile is the keyword defined for template with chain ID. > So when i use pdbfile for both 1SHW, 1SHX why it only takes the one with the 2nd entry. Like a normal variable initial template name changes when it is assigned to some other template. > > So what is the mistake in this set of lines? How should i solve this task. > > for (code, code, atomfile, chain) in (('1SHWA','1SHXA','1SHX','A'), > (pdbfile,pdbfile,fileName,'A')): > mdl = model(env, file=atomfile, model_segment=('FIRST:'+chain, 'LAST:'+chain)) > aln.append_model(mdl, atom_files=code, align_codes=atomfile) > > > > Thanks, > Ashish > > > > Ashish Runthala, > Lecturer, Structural Biology Cell, > Biological Sciences Group, > BITS, Pilani > Rajasthan, INDIA > > > ------------------------------ > > Message: 3 > Date: Mon, 31 Oct 2011 06:16:22 -0800 > From: junior sam.kauba@gmail.com > Subject: [modeller_usage] Build a model with multiple models > To: modeller_usage@salilab.org > Message-ID: > CAEJMx6wtgQ8U6MAG+uepWiwwcvTHbCvqFZ824_jJJS3cM2jciQ@mail.gmail.com > Content-Type: text/plain; charset=ISO-8859-1 > > Hi, > > > How do I build a PDB file containing more than 10 models? > > > Thank you. > > > > Sam Kauba > > > ------------------------------ > > _______________________________________________ > modeller_usage mailing list > modeller_usage@salilab.org > https://salilab.org/mailman/listinfo/modeller_usage > > > End of modeller_usage Digest, Vol 10, Issue 132 > *********************************************** > > >