BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Relax
Fluorite | Level 6

Hello All,

 

I have some JMP codes like below:

 

dt_a = dt_b << Multivariate(
Y( :Name( "A" ), :name( "B" ), :name( "C" ) ),
estimation method( "Row-wise" ),
invisible
);

 

I would like to replicate the results of these JMP codes in SAS.  I know PROC CORR may give the correlation, but I don't know how to use "Row-wise" method in this procedure.  Can someone help me?

 

PS: I am sorry if I posted this question in the wrong location.

1 ACCEPTED SOLUTION

Accepted Solutions
PaigeMiller
Diamond | Level 26

@Relax wrote:

Thanks for replying.

Yes, I want correlations using values of A, B and C in the same row.

Row-wise estimation is used for data tables with no missing values, so if a row occurs with missing B, but valid A and C, I will delete this row.


This is different than your previous explanation.

 

Try this

 

proc corr data=mydatasetname nomiss;
    var a b c;
run;
--
Paige Miller

View solution in original post

7 REPLIES 7
PaigeMiller
Diamond | Level 26

Please explain what JMP is doing when you say "row-wise"

--
Paige Miller
Relax
Fluorite | Level 6

Thanks for replying.  Row-wise estimation is used for data tables with no missing values and calculates the correlation of the variables in the same row.

PaigeMiller
Diamond | Level 26

@Relax wrote:

Thanks for replying.  Row-wise estimation is used for data tables with no missing values and calculates the correlation of the variables in the same row.


No missing values ...

 

proc corr data=mydatasetname;
    var a b c;
run;
--
Paige Miller
mkeintz
PROC Star

By "rowwise" do you mean your want correlations using values in the same row?

 

Second question: what do you want to do about missing values?  If you want correlations of A, B, and C, when a row occurs with missing B, but valid A and C, do you want that row to still contribute to generating the correlation of A and C?

--------------------------
The hash OUTPUT method will overwrite a SAS data set, but not append. That can be costly. Consider voting for Add a HASH object method which would append a hash object to an existing SAS data set

Would enabling PROC SORT to simultaneously output multiple datasets be useful? Then vote for
Allow PROC SORT to output multiple datasets

--------------------------
Relax
Fluorite | Level 6

Thanks for replying.

Yes, I want correlations using values of A, B and C in the same row.

Row-wise estimation is used for data tables with no missing values, so if a row occurs with missing B, but valid A and C, I will delete this row.

PaigeMiller
Diamond | Level 26

@Relax wrote:

Thanks for replying.

Yes, I want correlations using values of A, B and C in the same row.

Row-wise estimation is used for data tables with no missing values, so if a row occurs with missing B, but valid A and C, I will delete this row.


This is different than your previous explanation.

 

Try this

 

proc corr data=mydatasetname nomiss;
    var a b c;
run;
--
Paige Miller
Relax
Fluorite | Level 6

Thank you, Paige.  I appreciate your help.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 7 replies
  • 630 views
  • 0 likes
  • 3 in conversation