import System.Drawing
from System import Array
import clr
labels = ["blue", "green", "red"]
for i in range(3):
conv = ImageToArray(0, 255, i)
# there has to be a better way!
c = conv.Convert.Overloads[System.Drawing.Bitmap, clr.GetClrType(Array[float]).MakeByRefType()]
array = c(image.toBitmap())
ih = Histogram()
ih.Compute(array, 255)
d = [(bin.Range.Min, bin.Value) for bin in ih.Bins]
s = calico.GoogleChart("ColumnChart", ("x", labels[i]), d, {'logScale': 1, 'colors': [labels[i]]})
#calico.display(s.GetRepresentations()["text/html"])
calico.display(s)