MCPcopy Index your code
hub / github.com/plotly/plotly.py / make_hist

Method make_hist

plotly/figure_factory/_distplot.py:314–340  ·  view source on GitHub ↗

Makes the histogram(s) for FigureFactory.create_distplot(). :rtype (list) hist: list of histogram representations

(self)

Source from the content-addressed store, hash-verified

312 self.end.append(max(trace) * 1.0)
313
314 def make_hist(self):
315 """
316 Makes the histogram(s) for FigureFactory.create_distplot().
317
318 :rtype (list) hist: list of histogram representations
319 """
320 hist = [None] * self.trace_number
321
322 for index in range(self.trace_number):
323 hist[index] = dict(
324 type="histogram",
325 x=self.hist_data[index],
326 xaxis="x1",
327 yaxis="y1",
328 histnorm=self.histnorm,
329 name=self.group_labels[index],
330 legendgroup=self.group_labels[index],
331 marker=dict(color=self.colors[index % len(self.colors)]),
332 autobinx=False,
333 xbins=dict(
334 start=self.start[index],
335 end=self.end[index],
336 size=self.bin_size[index],
337 ),
338 opacity=0.7,
339 )
340 return hist
341
342 def make_kde(self):
343 """

Callers 1

create_distplotFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected