From 5ca60a1aaa7104f45997e4c012427b5bf4edb79d Mon Sep 17 00:00:00 2001 From: Yashwant Singh Parihar Date: Fri, 31 Jul 2020 18:14:01 +0530 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Ryan Curtin Co-authored-by: James J Balamuta --- README.md | 2 +- doc/guide/r_quickstart.hpp | 10 +++++----- src/mlpack/bindings/R/print_type_doc_impl.hpp | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 94b3d66827..8fc208fb58 100644 --- a/README.md +++ b/README.md @@ -122,7 +122,7 @@ If you would like to build the Julia bindings, make sure that Julia >= 1.3.0 is installed. If you would like to build the Go bindings, make sure that Go >= 1.11.0 is -installed with this package. +installed with this package: gonum diff --git a/doc/guide/r_quickstart.hpp b/doc/guide/r_quickstart.hpp index 25325e3b8c..e37cd2aa86 100644 --- a/doc/guide/r_quickstart.hpp +++ b/doc/guide/r_quickstart.hpp @@ -13,15 +13,17 @@ This quickstart guide is also available for @ref python_quickstart "Python" @ref cli_quickstart "the command-line", @ref julia_quickstart "Julia" and @ref go_quickstart "Go". -@section r_quickstart_install Installing mlpack +@section r_quickstart_install Installing mlpack binary package Installing the mlpack bindings for R is straightforward; you can just use -cran mirror: +CRAN mirror: @code{.R} install.packages('mlpack') @endcode +@section r_quickstart_install Installing mlpack package from source + Building the R bindings from scratch is a little more in-depth, though. For information on that, follow the instructions on the @ref build page, and be sure to specify @c -DBUILD_R_BINDINGS=ON to CMake; you may need to also set the @@ -167,9 +169,7 @@ Recommendations for user 1: @section r_quickstart_nextsteps Next steps with mlpack -Now that you have done some simple work with mlpack, you have seen how it can -easily plug into a data science workflow in R. A great thing to do next -would be to look at more documentation for the R mlpack bindings: +After working through this overview to `mlpack`'s R package, we hope you are inspired to use `mlpack`' in your data science workflow. We recommend as part of your next steps to look at more documentation for the R mlpack bindings: - R mlpack binding documentation diff --git a/src/mlpack/bindings/R/print_type_doc_impl.hpp b/src/mlpack/bindings/R/print_type_doc_impl.hpp index 878bfb836a..71dc640495 100644 --- a/src/mlpack/bindings/R/print_type_doc_impl.hpp +++ b/src/mlpack/bindings/R/print_type_doc_impl.hpp @@ -53,7 +53,7 @@ std::string PrintTypeDoc( // Not sure what it is... else { - throw std::invalid_argument("unknown parameter type " + data.cppType); + throw std::invalid_argument("Unknown parameter type '" + data.cppType + "'."); } } @@ -75,7 +75,7 @@ std::string PrintTypeDoc( } else { - throw std::invalid_argument("unknown vector type " + data.cppType); + throw std::invalid_argument("Unknown vector type '" + data.cppType + "'."); } } @@ -117,7 +117,7 @@ std::string PrintTypeDoc( } else { - throw std::invalid_argument("unknown matrix type " + data.cppType); + throw std::invalid_argument("Unknown matrix type '" + data.cppType + "'."); } }