As a follow up, I notice the size of the Edge.VertexData matrix no longer has a one to one correspondence with the number of data points in the plot. This seems to happen somewhere above 20,000 data points. I assume there is some function that reduces the number of line segments for efficiency. My issue is this produces an error when I create a ColorData matrix the size of the points used to create the plot, and then attempt to set the ColorData property. How can I reconcile this?
h = plot([0:.001:40],[0:.001:20 19.999:-.001:0])
h =
Line with properties:
Color: [0 0.4470 0.7410]
LineStyle: '-'
LineWidth: 0.5000
Marker: 'none'
MarkerSize: 6
MarkerFaceColor: 'none'
XData: [1x40001 double]
YData: [1x40001 double]
ZData: [1x0 double]
Show all properties
>> h.Edge.get
AlignVertexCenters: 'off'
AmbientStrength: 0.3000
ColorBinding: 'object'
ColorData: [4x1 uint8]
ColorType: 'truecolor'
DiffuseStrength: 0.6000
HandleVisibility: 'off'
HitTest: 'off'
Layer: 'middle'
LineCap: 'none'
LineJoin: 'round'
LineStyle: 'solid'
LineWidth: 0.5000
NormalBinding: 'none'
NormalData: []
Parent: [1x1 Line]
PickableParts: 'visible'
SpecularColorReflectance: 1
SpecularExponent: 10
SpecularStrength: 0.9000
StripData: [1 7474]
Texture: [0x0 GraphicsPlaceholder]
VertexData: [3x7473 single]
VertexIndices: []
Visible: 'on'
WideLineRenderingHint: 'software'