- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Posted 09-14-2018 12:45 PM
(3366 views)
how to write the code for sample mean vector for 3*3 matrix in SAS iml the equation for it is attached in the document
the matrix is {1 2 -1,
2 4 4,
1 5 -2};
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
MeanM = mean(myMatrix);
If you want it transposed, use the T()function.
IML functions are listed here
https://documentation.sas.com/?docsetId=imlug&docsetTarget=imlug_langref_sect253.htm&docsetVersion=1...
@Mustafa86 wrote:
how to write the code for sample mean vector for 3*3 matrix in SAS iml the equation for it is attached in the document
the matrix is {1 2 -1,
2 4 4,
1 5 -2};
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Post it at IML forum @Rick_SAS is there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
proc iml;
x = {1 2 -1,
2 4 4,
1 5 -2};
colMean = mean(x); /* means of each column */
print colMean;