# Scripting more hair keys than six

I need to write a script that allows me to bend a hair to exact coordinates. I've been using -

bpy.context.object.particle_systems[0].particles[0].hair_keys[0].co = (x,y,z)


but particles[0] seems to only allow 0-5 hair_keys.

Is there anyway to script an increase in the number of hair_keys? Any sample code would be greatly appreciated.

Thanks!