Ejemplo n.º 1
0
    def plot_area(self, experiments, choice):
        filter_dict = fpi_util.categorize(experiments, choice)

        # Get the actual data from the fpiexperiment and assign them to the genotype categories
        genotype_dict = defaultdict(dict)
        genotype_dict.update((k, {}) for k in [item for item in Genotype])
        for base_filter, genotypes in filter_dict.items():
            for genotype, exp_list in genotypes.items():
                genotype_dict[genotype][base_filter] = []
                genotype_dict[genotype][base_filter] = [
                    exp.area for exp in exp_list if exp.area is not None
                ]
        fpi_util.clear_data(genotype_dict)
        # Compute the positions of the boxplots
        self._plot_dict(genotype_dict)
Ejemplo n.º 2
0
    def plot_peak_latency(self, experiments, choice):
        filter_dict = fpi_util.categorize(experiments, choice)
        genotype_dict = defaultdict(dict)
        genotype_dict.update((k, {}) for k in [item for item in Genotype])

        # Loading the data into the genotype dict
        for base_filter, genotypes in filter_dict.items():
            for genotype, exp_list in genotypes.items():
                genotype_dict[genotype][base_filter] = []
                genotype_dict[genotype][base_filter] = [
                    exp.peak_latency for exp in exp_list
                    if exp.peak_latency is not None
                ]

        fpi_util.clear_data(genotype_dict)
        self._plot_dict(genotype_dict)
Ejemplo n.º 3
0
    def plot_peak_value(self, experiments, choice):
        filter_dict = fpi_util.categorize(experiments, choice)

        # Get the actual data from the fpiexperiment and assign them to the genotype categories

        # Get the actual data from the fpiexperiment and assign them to the genotype categories
        genotype_dict = defaultdict(dict)
        genotype_dict.update((k, {}) for k in [item for item in Genotype])
        for base_filter, genotypes in filter_dict.items():
            for genotype, exp_list in genotypes.items():
                genotype_dict[genotype][base_filter] = []
                genotype_dict[genotype][base_filter] = [
                    exp.max_df for exp in exp_list if exp.max_df is not None
                ]
        fpi_util.clear_data(genotype_dict)
        self._plot_dict(genotype_dict)
Ejemplo n.º 4
0
    def plot_baseline(self, experiments, choice):
        """

        :param experiments: FPIExperiment object list
        :param choice: A string returned from the util.BoxPlotChoices panel
        :return:
        """
        # Get the options for the current category
        filter_dict = fpi_util.categorize(experiments, choice)

        # Get the actual data from the fpiexperiment and assign them to the genotype categories
        genotype_dict = defaultdict(dict)
        genotype_dict.update((k, {}) for k in [item for item in Genotype])
        for base_filter, genotypes in filter_dict.items():
            for genotype, exp_list in genotypes.items():
                genotype_dict[genotype][base_filter] = []
                genotype_dict[genotype][base_filter] = [
                    exp.mean_baseline for exp in exp_list
                    if exp.mean_baseline is not None
                ]

        fpi_util.clear_data(genotype_dict)
        # Compute the positions of the boxplots
        self._plot_dict(genotype_dict)