Lets say I read in a 2x2 matrix from a SAS data set say, A=[1,2 ; 3,4] and I have to multiply it into a 3 dimensional column vector with a missing value say, x=(4, . ,6)'.
Now I know that proc IML doesnt like missing values so I have to first remove the missing value from x then I can do A*x and now I get a 2x1 column vector.
What I want to do now is reinsert the missing value into its original position as with the x vector. So in our case y=A*x=[16,36] and I want y to become y=[16, . , 36].
This was just a basic example. My x vectors may have multiple missing values at different indices. My A matrix will always be the dimension of the truncated x vector so I dont need to worry about my A matrix. All I need to do is truncate the missing values from my x vector, do the matrix multiplication, and then add the missing value character (.) in y where it initially was on x.
I am not that proficient in coding yet so any complete or semi-complete code would help.