[R] PLS LDA

2003-09-10 Thread Christoph Lehmann
Dear R experts
I saw and downloaded the fresh pls package for R. Is there any way of
using this pls package for PLS discriminant analysis? If not, is there
any other package available.

I need a way of classifying objects into e.g. two groups, where
nbr_observations  nbr_variables

many thanks for your kind help

Christoph
-- 
Christoph Lehmann [EMAIL PROTECTED]

__
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help


RE: [R] PLS LDA

2003-09-10 Thread Liaw, Andy
Do you mean the pls.pcr package by Prof. Wehrens?  This is what I do:

o  Code the two groups as 0s and 1s (numeric, not factor).

o  Run PLS as usual.  Cases with predicted values  0.5 get 
   classified as 1s, otherwise as 0s.

o  Note that you need to modify the code inside the mvr() 
   function a bit if you want to use the built-in selection
   of number of LVs:  It selects the number that gives the
   best MSE, but what you really want is the number that
   gives the best error rate.  One trick is to discretize
   the predictions in {0, 1}, then the MSE will be error
   rate.

There are better ways to do this, but this works fairly well.

HTH,
Andy 

 -Original Message-
 From: Christoph Lehmann [mailto:[EMAIL PROTECTED] 
 Sent: Wednesday, September 10, 2003 1:38 PM
 To: [EMAIL PROTECTED]
 Subject: [R] PLS LDA
 
 
 Dear R experts
 I saw and downloaded the fresh pls package for R. Is there 
 any way of using this pls package for PLS discriminant 
 analysis? If not, is there any other package available.
 
 I need a way of classifying objects into e.g. two groups, 
 where nbr_observations  nbr_variables
 
 many thanks for your kind help
 
 Christoph
 -- 
 Christoph Lehmann [EMAIL PROTECTED]
 
 __
 [EMAIL PROTECTED] mailing list 
 https://www.stat.math.ethz.ch/mailman/listinfo /r-help
 

--
Notice:  This e-mail message, together with any attachments,...{{dropped}}

__
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help


RE: [R] PLS LDA

2003-09-10 Thread Christoph Lehmann
Hi Andy

Great and thanks a lot! Yes, it is the package from Prof. Wehrens. So I
just run the PLS like a Logistic Regression, coding the endogenous
variable as binary. 
So no need of specifying a binary-link function (as we have to when
using glm)?
And yes of course: I need the LVs which give the best error rate. What
do you mean by discretize the predictions in {0, 1}? Does this mean I
assign a prediction either a 0 (if predicted values =0.5) or a 1 if the
predicted value is 0.5?
I need to dive into the package tomorrow, so that I better understand
the material, but is there any way of calculating e.g. a leaving-one-out
cross-validation error?

Thanks and best regards

Christoph

On Wed, 2003-09-10 at 21:50, Liaw, Andy wrote:
 Do you mean the pls.pcr package by Prof. Wehrens?  This is what I do:
 
 o  Code the two groups as 0s and 1s (numeric, not factor).
 
 o  Run PLS as usual.  Cases with predicted values  0.5 get 
classified as 1s, otherwise as 0s.
 
 o  Note that you need to modify the code inside the mvr() 
function a bit if you want to use the built-in selection
of number of LVs:  It selects the number that gives the
best MSE, but what you really want is the number that
gives the best error rate.  One trick is to discretize
the predictions in {0, 1}, then the MSE will be error
rate.
 
 There are better ways to do this, but this works fairly well.
 
 HTH,
 Andy 
 
  -Original Message-
  From: Christoph Lehmann [mailto:[EMAIL PROTECTED] 
  Sent: Wednesday, September 10, 2003 1:38 PM
  To: [EMAIL PROTECTED]
  Subject: [R] PLS LDA
  
  
  Dear R experts
  I saw and downloaded the fresh pls package for R. Is there 
  any way of using this pls package for PLS discriminant 
  analysis? If not, is there any other package available.
  
  I need a way of classifying objects into e.g. two groups, 
  where nbr_observations  nbr_variables
  
  many thanks for your kind help
  
  Christoph
  -- 
  Christoph Lehmann [EMAIL PROTECTED]
  
  __
  [EMAIL PROTECTED] mailing list 
  https://www.stat.math.ethz.ch/mailman/listinfo /r-help
  
 
 --
 Notice:  This e-mail message, together with any attachments,...{{dropped}}
 
 __
 [EMAIL PROTECTED] mailing list
 https://www.stat.math.ethz.ch/mailman/listinfo/r-help
-- 
Christoph Lehmann [EMAIL PROTECTED]

__
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help