def na(): cmd.view('v', 'store') object = cmd.get_names()[0] if object[0] == 'd': pdbid = object[1:5] chainid = object[5:6] else: pdbid = object[0:4] chainid = object[4:5] cmd.fetch(pdbid) cmd.select("design_na", "%s and chain %s and not hydro" % (object, "B")) cmd.select("native_na", "%s and chain %s and not hydro" % (pdbid, chainid)) cmd.select("other_na", "%s and not chain %s" % (pdbid, chainid)) cmd.hide("everything", "other") cmd.hide('(resn HOH)') cmd.super("native_na", "design_na") cmd.hide("lines", "all") cmd.show("sticks", "native_na") cmd.show("cartoon", "native_na") cmd.select("none") cmd.orient(object) pdbid = pdbid.lower() cmd.system("rm %s.pdb" % (pdbid)) cmd.view('v', 'recall')
def nat(pdbid, chainid): cmd.view('v', 'store') object = cmd.get_names()[0] cmd.fetch(pdbid) cmd.select("design_nat", "%s and chain %s and not hydro" % (object, "B")) cmd.select("native_nat", "%s and chain %s and not hydro" % (pdbid, chainid)) cmd.select("other_nat", "%s and not chain %s" % (pdbid, chainid)) cmd.hide("everything", "other") cmd.hide('(resn HOH)') cmd.super("design_nat", "native_nat") cmd.select("none") cmd.orient(object) cmd.hide("lines", "all") cmd.show("sticks", "native_nat") cmd.show("cartoon", "native_nat") cmd.system("rm %s.pdb" % (pdbid)) cmd.view('v', 'recall')
def nat(pdbid,chainid): cmd.view('v', 'store'); object = cmd.get_names()[0] cmd.fetch(pdbid) cmd.select("design_nat","%s and chain %s and not hydro"%(object,"B")) cmd.select("native_nat","%s and chain %s and not hydro"%(pdbid,chainid)) cmd.select("other_nat","%s and not chain %s"%(pdbid,chainid)) cmd.hide("everything","other") cmd.hide('(resn HOH)') cmd.super("design_nat","native_nat") cmd.select("none") cmd.orient(object) cmd.hide("lines","all"); cmd.show("sticks","native_nat"); cmd.show("cartoon","native_nat"); cmd.system("rm %s.pdb"%(pdbid)); cmd.view('v', 'recall')
def na(): cmd.view('v', 'store'); object = cmd.get_names()[0] pdbid = object[0:4] chainid = object[4:5] cmd.fetch(pdbid) cmd.select("design_na","%s and chain %s"%(object,"B")) cmd.select("native_na","%s and chain %s"%(pdbid,chainid)) cmd.select("other_na","%s and not chain %s"%(pdbid,chainid)) cmd.hide("everything","other") cmd.hide('(resn HOH)') cmd.super("design_na","native_na") cmd.select("none") cmd.orient(object) cmd.system("rm %s.pdb"%(pdbid)); cmd.view('v', 'recall')
def na(): cmd.view('v', 'store'); object = cmd.get_names()[0] if object[0] == 'd': pdbid = object[1:5] chainid = object[5:6] else: pdbid = object[0:4] chainid = object[4:5] cmd.fetch(pdbid) cmd.select("design_na","%s and chain %s and not hydro"%(object,"B")) cmd.select("native_na","%s and chain %s and not hydro"%(pdbid,chainid)) cmd.select("other_na","%s and not chain %s"%(pdbid,chainid)) cmd.hide("everything","other") cmd.hide('(resn HOH)') cmd.super("native_na","design_na") cmd.hide("lines","all"); cmd.show("sticks","native_na"); cmd.show("cartoon","native_na"); cmd.select("none") cmd.orient(object) pdbid = pdbid.lower() cmd.system("rm %s.pdb"%(pdbid)); cmd.view('v', 'recall')
def na(): cmd.view('v', 'store') object = cmd.get_names()[0] pdbid = object[0:4] chainid = object[4:5] cmd.fetch(pdbid) cmd.select("design_na", "%s and chain %s" % (object, "B")) cmd.select("native_na", "%s and chain %s" % (pdbid, chainid)) cmd.select("other_na", "%s and not chain %s" % (pdbid, chainid)) cmd.hide("everything", "other") cmd.hide('(resn HOH)') cmd.super("design_na", "native_na") cmd.select("none") cmd.orient(object) cmd.system("rm %s.pdb" % (pdbid)) cmd.view('v', 'recall')
def info(): object = cmd.get_names()[0] if object[0] == 'd': pdbid = object[1:5] chainid = object[5:6] else: pdbid = object[0:4] chainid = object[4:5] pdbid = pdbid.lower() cmd.system("open http://pdb.org/pdb/explore/explore.do?structureId=%s"%(pdbid))
def info(): object = cmd.get_names()[0] if object[0] == 'd': pdbid = object[1:5] chainid = object[5:6] else: pdbid = object[0:4] chainid = object[4:5] pdbid = pdbid.lower() cmd.system("open http://pdb.org/pdb/explore/explore.do?structureId=%s" % (pdbid))
#index = sys.argv.index("--") #params = sys.argv[index:] #if(len(params) == 2): #path = params[1] #cmd.cd(path) #else: #print "No Path specified" except ValueError: print "No Path specified" for file in glob("*.pdb"): print "file: ", file listname = file.split(".") name = listname[0] cmd.load(file, name) cmd.system("mv " + file + " ../pdb/") cmd.hide("all") cmd.show("sticks") cmd.reset() cmd.origin(position=[0.0, 0.0, 0.0]) cmd.save(name + "stix.wrl") cmd.hide("all") cmd.show("ribbon") cmd.reset() cmd.origin(position=[0.0, 0.0, 0.0]) cmd.save(name + "rib.wrl") cmd.hide("all") preset.pretty(name) cmd.reset() cmd.origin(position=[0.0, 0.0, 0.0]) cmd.save(name + "cart.wrl")
#index = sys.argv.index("--") #params = sys.argv[index:] #if(len(params) == 2): #path = params[1] #cmd.cd(path) #else: #print "No Path specified" except ValueError: print "No Path specified" for file in glob("*.pdb"): print "file: ", file listname = file.split(".") name = listname[0]; cmd.load(file, name) cmd.system("mv " + file + " ../pdb/") cmd.hide("all") cmd.show("sticks") cmd.reset() cmd.origin(position=[0.0,0.0,0.0]) cmd.save(name + "stix.wrl") cmd.hide("all") cmd.show("ribbon") cmd.reset() cmd.origin(position=[0.0,0.0,0.0]) cmd.save(name + "rib.wrl") cmd.hide("all") preset.pretty(name) cmd.reset() cmd.origin(position=[0.0,0.0,0.0]) cmd.save(name + "cart.wrl")