(hist)
return x, y
Tesselates histograms.
    
    Arguments:
      * hist: a N x Nsamples array, where each line contains an histogram.
      
    Returns:
      * X, Y: two N x (5 * Nsamples + 1) arrays with the coordinates of the
        histograms, to be rendered as a TriangleStrip.
Tesselates histograms.
    
    Arguments:
      * hist: a N x Nsamples array, where each line contains an histogram.
      
    Returns:
      * X, Y: two N x (5 * Nsamples + 1) arrays with the coordinates of the
        histograms, to be rendered as a TriangleStrip.
Tesselates histograms . Arguments : * hist : a N x Nsamples array where each line contains an histogram . Returns : * X Y : two N x ( 5 * Nsamples + 1 ) arrays with the coordinates of the histograms to be rendered as a TriangleStrip .
def get_histogram_points(hist):
    """Tesselates histograms.
    
    Arguments:
      * hist: a N x Nsamples array, where each line contains an histogram.
      
    Returns:
      * X, Y: two N x (5 * Nsamples + 1) arrays with the coordinates of the
        histograms, to be rendered as a TriangleStrip.
      
    """
    n, nsamples = hist.shape
    dx = 1. / nsamples
    
    x0 = dx * np.arange(nsamples)
    
    x = np.zeros((n, 5 * nsamples + 1))
    y = np.zeros((n, 5 * nsamples + 1))
    
    x[:,0:-1:5] = x0
    x[:,1::5] = x0
    x[:,2::5] = x0 + dx
    x[:,3::5] = x0
    x[:,4::5] = x0 + dx
    x[:,-1] = 1
    
    y[:,1::5] = hist
    y[:,2::5] = hist
    
    return x, y
def get_histogram_points ( hist ) : n , nsamples = hist . shape dx = 1. / nsamples x0 = dx * np . arange ( nsamples ) x = np . zeros ( ( n , 5 * nsamples + 1 ) ) y = np . zeros ( ( n , 5 * nsamples + 1 ) ) x [ : , 0 : - 1 : 5 ] = x0 x [ : , 1 : : 5 ] = x0 x [ : , 2 : : 5 ] = x0 + dx x [ : , 3 : : 5 ] = x0 x [ : , 4 : : 5 ] = x0 + dx x [ : , - 1 ] = 1 y [ : , 1 : : 5 ] = hist y [ : , 2 : : 5 ] = hist return x , y