Help using Base SAS procedures

proc pls and logarithm

Accepted Solution Solved
Reply
Frequent Contributor
Posts: 75
Accepted Solution

proc pls and logarithm

Hi,

My man-a told me recently there is a way to have a PLS with logarithm.

However , I checked on the proc pls documentation and I found nothing relevant. I looked on the internet and I found nothing relevant as well.

Does anyone of you have any ideas?

Best.


Accepted Solutions
Solution
‎05-28-2014 08:08 AM
Trusted Advisor
Posts: 1,931

Re: proc pls and logarithm

This is not mentioned in the help documentation for PROC PLS, and doesn't work for me in SAS 9.4.

You need to create the logarithm of the variable in a data step prior to PROC PLS, and then you can use that logarithm as the Y variable in PROC PLS.

View solution in original post


All Replies
Frequent Contributor
Posts: 75

Re: proc pls and logarithm

After talking with my colleague, it seems I have the beginnning of a hint:

proc pls data=dataset ;

model log(Y) = x1 ... xn;

output out=datasetname predicted=var_name;

run;

Thank you all for reading.

Solution
‎05-28-2014 08:08 AM
Trusted Advisor
Posts: 1,931

Re: proc pls and logarithm

This is not mentioned in the help documentation for PROC PLS, and doesn't work for me in SAS 9.4.

You need to create the logarithm of the variable in a data step prior to PROC PLS, and then you can use that logarithm as the Y variable in PROC PLS.

Frequent Contributor
Posts: 75

Re: proc pls and logarithm

Posted in reply to PaigeMiller

Paige,

I've got a quick one. I took the following option : not Log Y = Log X

I got that error message

NOTE: Maximum number of factors to extract set to 15.  This may be too high; you should consider using either NFAC= or

      the CV= to set the number of factors.

WARNING: Data scaling prevents scores and loadings from being represented as correlations; Correlation Loading Plot not

         produced.

Do you have any idea why?

Cheers.

Trusted Advisor
Posts: 1,931

Re: proc pls and logarithm

I have no idea what this means

I took the following option : not Log Y = Log X

but if you want someone to explain your error message, then we would need to see the relevant parts of the SASLOG, including the actual code that produced the error messages.

Frequent Contributor
Posts: 75

Re: proc pls and logarithm

Hi Paige,

You are right.

I double checked with my colleague and we need to have the dataset transformed to log , prior to the PLS.

I did the 3 following combinations :

Log Y = not log X

not Log Y = Log X

Log Y = Log X

Then with my need, I'm using one of the transformed dataset for the proc PLS. Y has only one variable.

Thanks for the feedback.

Frequent Contributor
Posts: 75

Re: proc pls and logarithm

I meant I chose Y has not been changed to log and all the Xs have been changed to log.

Thanks for your help. I will do my homework thoroughly before putting my code and my log.

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 6 replies
  • 380 views
  • 3 likes
  • 2 in conversation