LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (July 2008, week 4)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 28 Jul 2008 09:15:38 -0500
Reply-To:     "data _null_," <datanull@GMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "data _null_," <datanull@GMAIL.COM>
Subject:      Re: Correlation output
Comments: To: valkrem@yahoo.com
In-Reply-To:  <447867.21322.qm@web63607.mail.re1.yahoo.com>
Content-Type: text/plain; charset=ISO-8859-1

I think the WITH statement will give you the matrix that you want. But it is a bit hard to tell what you had already done because you did not show that.

data test; array v[12]; do _n_ = 1 to 10; do i = 1 to dim(v); v[i] = rannor(10002)+3 *3.2; output; end; end; run;

proc corr outp=work.corr; var v1-v2; with v3-v12; run;

proc print; run; On 7/28/08, Val Krem <valkrem@yahoo.com> wrote: > Dear SAs users, > I am doing a correlation analysis two variables against several variables (>100). the default SAS out put givs N X N matrix which is very hard to read it. > > Is it possible to change the out put to N x 2 as shown below? > > Val > > > > > > > > > > > > > > Default output > > > > > X > v1 > v2 > v3 > v4 > v5 > > > > > v1 > 1 > 0.95 > 0.68 > 0.5 > 0.1 > > > > > v2 > 0.95 > 1 > -0.21 > -0.5 > 0.9 > > > > > v3 > 0.68 > > > 1 > > > > > > > > > v4 > 0.45 > > > > > 1 > > > > > > > v5 > 0.12 > > > > > > > 1 > > > > > > > > > > > > > > > > > > > > > Desired output > > > > > > > > > > > > > v1 > v2 > > > > > > > > > > > v1 > 1 > 0.95 > > > > > > > > > > > v2 > 0.95 > 1 > > > > > > > > > > > v3 > 0.68 > -0.21 > > > > > > > > > > > v4 > 0.45 > -0.45 > > > > > > > > > > > v5 > 0.12 > 0.89 > > > > > > > > > > > > >


Back to: Top of message | Previous page | Main SAS-L page