Hallo Scilab experts,
Given is a numeric vector x of length n and an index vector i with max(i)=n. I want to insert a %nan after every x(i).

Example
x=[11:20]
i=[2 5 8]
Required result: y=[11 12 %nan 13 14 15 %nan 16 17 18 %nan 19 20]

How would you proceed so that it works fast for n>500000 too.

Kind regards

Jens


_______________________________________________
users mailing list
[email protected]
http://lists.scilab.org/mailman/listinfo/users

Reply via email to