Updated pull request based on your feedbacks.

Thanks!

Shaoshan

From: Sharad Gandhi <notifications@github.com<mailto:notifications@github.com>>
Reply-To: linkedin/naarad <reply@reply.github.com<mailto:reply@reply.github.com>>
Date: Wednesday, March 5, 2014 12:24 PM
To: linkedin/naarad <naarad@noreply.github.com<mailto:naarad@noreply.github.com>>
Cc: Shaoshan Liu <shliu@linkedin.com<mailto:shliu@linkedin.com>>
Subject: Re: [naarad] Add CDF support to Naarad (#143)


In src/naarad/metrics/metric.py:

> +        plot_data = [PD(input_csv=percentile_csv, csv_column=1, series_name=graph_title, y_label=column +' ('+ self.sub_metric_unit[column]+')', precision=None, graph_height=600, graph_width=1200, graph_type='line')]
> +      else:
> +        plot_data = [PD(input_csv=percentile_csv, csv_column=1, series_name=graph_title, y_label=column, precision=None, graph_height=600, graph_width=1200, graph_type='line')]
> +      graphed, div_file = Metric.graphing_modules[graphing_library].graph_data(plot_data, self.resource_directory, self.resource_path, graph_title, 'cdf')
> +      if graphed:
> +        self.plot_files.append(div_file)
> +    return True
> +
> +  def graph(self, graphing_library = 'matplotlib'):
> +    """
> +    graph generates two types of graphs
> +    'time': generate a time-series plot for all submetrics (the x-axis is a time series)
> +    'cdf': generate a CDF plot for important submetrics (the x-axis shows percentiles)
> +    """
> +    html_string = []
> +    html_string.append('<h1>Metric: {0}</h1>\n'.format(self.metric_type))


Ye, line 362 & 363 can be deleted. Its leftover of initial naarad report

—
Reply to this email directly or view it on GitHub<https://github.com/linkedin/naarad/pull/143/files#r10316685>.