How can I get vertices colorful

Hi guys,
I am making a simulation with blender,
I would like to draw a sphere with different colors at different vertex.
here is the code for python:

for count in range(0, len(linesphere)):
me = NMesh.GetRaw()
mat = Material.New(‘Material’)
me.materials.append(mat)
mat.rgbCol = [float(line[count])/100, float(line[count])/100, float(line[count])/100]
mat.setAlpha(1.0)
pos = linesphere[count].split(’, ')
print pos
vert = NMesh.Vert(float(pos[0]), float(pos[1]), float(pos[2]))
me.verts.append(vert)
NMesh.PutRaw(me)

Since there is only vertex, that is, there is no face.
how could I get this through?
THANK YOU VERY MUCH:confused:

try 2.45 and add a new Mesh Template from the text editors file window.

Colors are stored on the faces so try this after the text # Examples


    for f in me.faces:
      for col in f.col
        col.r = 255
        col.g = 0
        col.b = 128

You can mess around from there.