LDA as a dimensionality reducer [on hold]
$begingroup$
I know how to use LDA as a classifier.
But how to use Linear Discriminant Analysis as a dimensionality reducer to reduce the number of features and apply logistic regression on top of it.
I am using R language.
r feature-selection lda
New contributor
$endgroup$
put on hold as unclear what you're asking by Ethan, oW_, Mark.F, Sean Owen♦ yesterday
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
add a comment |
$begingroup$
I know how to use LDA as a classifier.
But how to use Linear Discriminant Analysis as a dimensionality reducer to reduce the number of features and apply logistic regression on top of it.
I am using R language.
r feature-selection lda
New contributor
$endgroup$
put on hold as unclear what you're asking by Ethan, oW_, Mark.F, Sean Owen♦ yesterday
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
$begingroup$
Please provide more context about the problem . btw the wording makes it sound like a homework assignment: in particular the somewhat "random" toss-in of "applying logistic regression" without explaining why that were chosen
$endgroup$
– javadba
2 days ago
$begingroup$
Please consider editing your question. In its' current form it is at risk of being closed.
$endgroup$
– Ethan
2 days ago
$begingroup$
I am trying to apply feature selection and go with logistic regression,instead of going blindly with random forest. My independent features being continuous and dependent categorical variable I am going with Linear Discriminant Analysis for feature selection, prior to applying logistic regression.
$endgroup$
– s.saptha maaleekaa
yesterday
add a comment |
$begingroup$
I know how to use LDA as a classifier.
But how to use Linear Discriminant Analysis as a dimensionality reducer to reduce the number of features and apply logistic regression on top of it.
I am using R language.
r feature-selection lda
New contributor
$endgroup$
I know how to use LDA as a classifier.
But how to use Linear Discriminant Analysis as a dimensionality reducer to reduce the number of features and apply logistic regression on top of it.
I am using R language.
r feature-selection lda
r feature-selection lda
New contributor
New contributor
edited yesterday
s.saptha maaleekaa
New contributor
asked 2 days ago
s.saptha maaleekaas.saptha maaleekaa
32
32
New contributor
New contributor
put on hold as unclear what you're asking by Ethan, oW_, Mark.F, Sean Owen♦ yesterday
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
put on hold as unclear what you're asking by Ethan, oW_, Mark.F, Sean Owen♦ yesterday
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
$begingroup$
Please provide more context about the problem . btw the wording makes it sound like a homework assignment: in particular the somewhat "random" toss-in of "applying logistic regression" without explaining why that were chosen
$endgroup$
– javadba
2 days ago
$begingroup$
Please consider editing your question. In its' current form it is at risk of being closed.
$endgroup$
– Ethan
2 days ago
$begingroup$
I am trying to apply feature selection and go with logistic regression,instead of going blindly with random forest. My independent features being continuous and dependent categorical variable I am going with Linear Discriminant Analysis for feature selection, prior to applying logistic regression.
$endgroup$
– s.saptha maaleekaa
yesterday
add a comment |
$begingroup$
Please provide more context about the problem . btw the wording makes it sound like a homework assignment: in particular the somewhat "random" toss-in of "applying logistic regression" without explaining why that were chosen
$endgroup$
– javadba
2 days ago
$begingroup$
Please consider editing your question. In its' current form it is at risk of being closed.
$endgroup$
– Ethan
2 days ago
$begingroup$
I am trying to apply feature selection and go with logistic regression,instead of going blindly with random forest. My independent features being continuous and dependent categorical variable I am going with Linear Discriminant Analysis for feature selection, prior to applying logistic regression.
$endgroup$
– s.saptha maaleekaa
yesterday
$begingroup$
Please provide more context about the problem . btw the wording makes it sound like a homework assignment: in particular the somewhat "random" toss-in of "applying logistic regression" without explaining why that were chosen
$endgroup$
– javadba
2 days ago
$begingroup$
Please provide more context about the problem . btw the wording makes it sound like a homework assignment: in particular the somewhat "random" toss-in of "applying logistic regression" without explaining why that were chosen
$endgroup$
– javadba
2 days ago
$begingroup$
Please consider editing your question. In its' current form it is at risk of being closed.
$endgroup$
– Ethan
2 days ago
$begingroup$
Please consider editing your question. In its' current form it is at risk of being closed.
$endgroup$
– Ethan
2 days ago
$begingroup$
I am trying to apply feature selection and go with logistic regression,instead of going blindly with random forest. My independent features being continuous and dependent categorical variable I am going with Linear Discriminant Analysis for feature selection, prior to applying logistic regression.
$endgroup$
– s.saptha maaleekaa
yesterday
$begingroup$
I am trying to apply feature selection and go with logistic regression,instead of going blindly with random forest. My independent features being continuous and dependent categorical variable I am going with Linear Discriminant Analysis for feature selection, prior to applying logistic regression.
$endgroup$
– s.saptha maaleekaa
yesterday
add a comment |
1 Answer
1
active
oldest
votes
$begingroup$
We can do LDA via the lda function from the MASS package. The reduced dimension data can be computed as follows:
# Model Discriminant Analysis
library( MASS )
model = lda( class ~ ., data = X_train )
# Ploting LDA Model
projected_data = as.matrix( X_train[, 1:18] ) %*% model$scaling
You can then feed the projected_data into another supervised learning method.
Credit: The code is obtained from here.
$endgroup$
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
We can do LDA via the lda function from the MASS package. The reduced dimension data can be computed as follows:
# Model Discriminant Analysis
library( MASS )
model = lda( class ~ ., data = X_train )
# Ploting LDA Model
projected_data = as.matrix( X_train[, 1:18] ) %*% model$scaling
You can then feed the projected_data into another supervised learning method.
Credit: The code is obtained from here.
$endgroup$
add a comment |
$begingroup$
We can do LDA via the lda function from the MASS package. The reduced dimension data can be computed as follows:
# Model Discriminant Analysis
library( MASS )
model = lda( class ~ ., data = X_train )
# Ploting LDA Model
projected_data = as.matrix( X_train[, 1:18] ) %*% model$scaling
You can then feed the projected_data into another supervised learning method.
Credit: The code is obtained from here.
$endgroup$
add a comment |
$begingroup$
We can do LDA via the lda function from the MASS package. The reduced dimension data can be computed as follows:
# Model Discriminant Analysis
library( MASS )
model = lda( class ~ ., data = X_train )
# Ploting LDA Model
projected_data = as.matrix( X_train[, 1:18] ) %*% model$scaling
You can then feed the projected_data into another supervised learning method.
Credit: The code is obtained from here.
$endgroup$
We can do LDA via the lda function from the MASS package. The reduced dimension data can be computed as follows:
# Model Discriminant Analysis
library( MASS )
model = lda( class ~ ., data = X_train )
# Ploting LDA Model
projected_data = as.matrix( X_train[, 1:18] ) %*% model$scaling
You can then feed the projected_data into another supervised learning method.
Credit: The code is obtained from here.
edited yesterday
answered yesterday
Siong Thye GohSiong Thye Goh
1,212418
1,212418
add a comment |
add a comment |
$begingroup$
Please provide more context about the problem . btw the wording makes it sound like a homework assignment: in particular the somewhat "random" toss-in of "applying logistic regression" without explaining why that were chosen
$endgroup$
– javadba
2 days ago
$begingroup$
Please consider editing your question. In its' current form it is at risk of being closed.
$endgroup$
– Ethan
2 days ago
$begingroup$
I am trying to apply feature selection and go with logistic regression,instead of going blindly with random forest. My independent features being continuous and dependent categorical variable I am going with Linear Discriminant Analysis for feature selection, prior to applying logistic regression.
$endgroup$
– s.saptha maaleekaa
yesterday