def create_case_widget(self): controller = self.controller if controller.ds is None: return by_signature = Checkbox( description='Cases indicated by signature?', value=self.by_signature ) case_id = Text(description='* Analysis for case:') if 'biological_constraints' not in controller.options: bio_constraints = '' else: bio_constraints = ', '.join(controller.defaults('biological_constraints')) constraints = Textarea(description='Biological constraints:', value=bio_constraints) button = Button(description='Create Analysis') button.on_click(self.create_report) button.case_id = case_id button.by_signature = by_signature button.constraints = constraints wi = VBox(children=[by_signature, case_id, constraints, button]) return ('Analyze Case', wi)
def colocalization_widget(self): controller = self.controller cases = Textarea(description='* Cases to co-localize:') by_signature = Checkbox(description='Cases indicated by signature?', value=self.by_signature) slice_variables = Textarea(description='* Slice variables:') if 'biological_constraints' not in controller.options: bio_constraints = '' else: bio_constraints = ', '.join(controller.defaults('biological_constraints')) constraints = Textarea(description='Biological constraints:', value=bio_constraints) button = Button(description='Create Co-Localization') button.on_click(self.make_colocalization) button.cases = cases button.by_signature = by_signature button.slice_variables = slice_variables button.constraints = constraints wi = VBox(children=[cases, by_signature, slice_variables, constraints, button]) return ('Co-localizations', wi)