Scaling only part of a mesh.

fname=‘UnitVector01’;

p1=(0,0,0);
p2=(.9,0,0);
Util.cylinder_between(p1[0],p1[1],p1[2],p2[0],p2[1],p2[2],.01);
bpy.context.object.name=“temp1”;

bpy.ops.mesh.primitive_cone_add(
radius1=0.019, radius2=0.0,
vertices=16,
depth=0.1,
view_align=False,
enter_editmode=False,
location=(0,0,0),
rotation=(0, 0, 0));

bpy.context.object.name=“temp2”;
bpy.context.scene.cursor_location = (0.0, 0.0, -0.05);
bpy.ops.object.origin_set(type=‘ORIGIN_CURSOR’);
bpy.context.object.location=(0.9,0,0);
bpy.context.object.rotation_euler[1]=(math.pi/2);

bpy.ops.object.select_all(action=‘DESELECT’);
bpy.data.objects[‘temp1’].select=True;
bpy.data.objects[‘temp2’].select=True;
bpy.ops.object.join();
bpy.context.object.name=fname;
bpy.context.scene.cursor_location = (0.0, 0.0, 0.0);
bpy.ops.object.origin_set(type=‘ORIGIN_CURSOR’);

I made this small script that creates a mesh designed to visualize vectors in space. By my design one can scale the mesh using the psuedo_object.scale[2]=yourscalehere; property however doing so will deform the shape of the cone or arrow as one might call it. I am familiar with the concept of an armature and have begun to study how they work but it is unclear to me yet if an armature can or can not be used to scale only the shaft of the mesh and not the arrow which is actually my intent to be doing. Is it possible perhaps with some additional code to be able to scale only the shaft or cylindrical portion of the joined mesh without deforming or changing at all the cone or arrow point as it might be named.

Thank you.

you would need to change cylinder before you join the 2 objects
or select in edit mode only the cylinder part and scale it

happy bl