Package schrodinger :: Package application :: Package msv :: Module utils
[hide private]
[frames] | no frames]

Module utils

Classes [hide private]
  BaseSignalAttribute
A util class for handling emitting a signal while changing an attribute.
  IdentityMapping
An identity mapping is a dictionary for mutable objects that uses the id for the object as the key.
Functions [hide private]
list
get_rolling_average(data, window_padding=2)
Returns the running average of data in a window
list of tuples
get_signals(source)
Utility method for iterating through the signals on a QObject.
Variables [hide private]
  __package__ = 'schrodinger.application.msv'
Function Details [hide private]

get_rolling_average(data, window_padding=2)

 

Returns the running average of data in a window

Parameters:
  • data (list) - Data to average
  • window_padding (int) - The number of elements on either side of a given element to include in the average
Returns: list
A list of rolling averages (or None values)

get_signals(source)

 

Utility method for iterating through the signals on a QObject.

Parameters:
  • source (QtCore.QObject or instance thereof) - Any object or class with signals
  • filter (tuple of strings) - Any signals to ignore
Returns: list of tuples
A list of (name, signal) tuples