Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SPARK-23461][R]vignettes should include model predictions for some ML models #21678

Closed
wants to merge 1 commit into from

Conversation

huaxingao
Copy link
Contributor

What changes were proposed in this pull request?

Add model predictions for Linear Support Vector Machine (SVM) Classifier, Logistic Regression, GBT, RF and DecisionTree in vignettes.

How was this patch tested?

Manually ran the test and checked the result.

@SparkQA
Copy link

SparkQA commented Jun 30, 2018

Test build #92492 has finished for PR 21678 at commit 85ad256.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

Copy link
Member

@felixcheung felixcheung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you check what the output pdf/html content looks like? we sometimes has a long or unreadable output, that doesn't quite fit in the vignettes

@huaxingao
Copy link
Contributor Author

Here is the output for Linear SVM Classifier in sparkr-vignettes.html.

prediction <- predict(model, training)
head(select(prediction, "Class", "Sex", "Age", "Freq", "Survived", "prediction"))
##   Class    Sex   Age Freq Survived prediction
## 1   1st   Male Child    0       No        Yes
## 2   2nd   Male Child    0       No        Yes
## 3   3rd   Male Child   35       No        Yes
## 4  Crew   Male Child    0       No        Yes
## 5   1st Female Child    0       No        Yes
## 6   2nd Female Child    0       No        Yes

@felixcheung
Copy link
Member

ok then, thanks

@felixcheung
Copy link
Member

LGTM

@felixcheung
Copy link
Member

merged to master

@asfgit asfgit closed this in 006e798 Jul 11, 2018
@huaxingao
Copy link
Contributor Author

@felixcheung Thanks a lot for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants