Actually - why are you using a scatter chart type? If you use the line, this functionality will be added by default and visual output will be the same.
I haven't tested it in this way. Thanks. One conditional 'if' fixed the case.Try hiding both the centroids in previous demo of yours , the first series lines re-appear.