Hello,
I have a matrix(25,127) B and a vector(1,88) C which has random numbers 1 to 127. I would like to extract columns from the matrix B Into a smaller matrix (25,88) A based on the values in the vector C. In other words, vector C has 1,2,5... 126, 127 (88 values) which indicate columns to extract from matrix B. How can I reference a vector to extract columns from matrix? Thanks
Matrix
Moderators: EViews Gareth, EViews Steve, EViews Moderator, EViews Jason
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13600
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Matrix
Code: Select all
matrix newb = b.@col(c)
Who is online
Users browsing this forum: No registered users and 2 guests
