ViewDock

From DISI
Revision as of 14:03, 27 March 2020 by Jwagsta (talk | contribs)
Jump to navigation Jump to search

ViewDock is a UCSF Chimera extension for viewing outputs from several docking software packages. There is a tutorial on the Chimera web pages.

Keyboard shortcuts

Using ViewDock as designed requires a fair amount of clicking and mouse movement. To reduce these one option is to do the following.

Create a Chimera accelerators script containing this code, originally written by Tom Goddard:

def register_accelerators():
    from Accelerators import standard_accelerators
    standard_accelerators.register_accelerators()

    from Accelerators import add_accelerator
    add_accelerator('cd', 'Mark current View Dock compound deleted', vdock_delete)
    add_accelerator('cx', 'Mark current View Dock compound purged', vdock_purged)
    add_accelerator('cv', 'Mark current View Dock compound viable', vdock_viable)


def vdock_delete():
    from ViewDock.Compound import Compound
    vdock_set_state(Compound.Deleted)

def vdock_purged():
    from ViewDock.Compound import Compound
    vdock_set_state(Compound.Purged)

def vdock_viable():
    from ViewDock.Compound import Compound
    vdock_set_state(Compound.Viable)

def vdock_set_state(state):
    vd = vdock_dialog()
    if vd:
        vd.results.setSelectedState(state)
        vd._reloadCompounds()

def vdock_dialog():
    from ViewDock import ViewDock
    from chimera import extension
    for vd in extension.manager.instances:
        if isinstance(vd, ViewDock):
            return vd
    return None

Then enable Chimera keyboard shortcuts and load the new file.

When looking at your compounds, initially assign them all status "Deleted" and show only "Deleted" compounds by choosing Compounds > List Deleted in the compound table dialog. Use accelerators "cv"and "cx" to reassign "Purged", and "Viable" statuses.