Skip to content

Commit 6f562b6

Browse files
author
irkaal
committed
Help documentation updates
1 parent 5097d4a commit 6f562b6

37 files changed

+70
-70
lines changed

R/aaa_models.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ check_interface_val <- function(x) {
329329
#' @keywords internal
330330
#' @details These functions are available for users to add their
331331
#' own models or engines (in package or otherwise) so that they can
332-
#' be accessed using `parsnip`. This are more thoroughly documented
332+
#' be accessed using `parsnip`. This is more thoroughly documented
333333
#' on the package web site (see references below).
334334
#'
335335
#' In short, `parsnip` stores an environment object that contains

R/boost_tree.R

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#' randomly sampled at each split when creating the tree models.
1212
#' \item \code{trees}: The number of trees contained in the ensemble.
1313
#' \item \code{min_n}: The minimum number of data points in a node
14-
#' that are required for the node to be split further.
14+
#' that is required for the node to be split further.
1515
#' \item \code{tree_depth}: The maximum depth of the tree (i.e. number of
1616
#' splits).
1717
#' \item \code{learn_rate}: The rate at which the boosting algorithm adapts
@@ -23,10 +23,10 @@
2323
#' stopping.
2424
#' }
2525
#' These arguments are converted to their specific names at the
26-
#' time that the model is fit. Other options and argument can be
27-
#' set using the `set_engine()` function. If left to their defaults
26+
#' time that the model is fit. Other options and arguments can be
27+
#' set using the `set_engine()` function. If left to their defaults
2828
#' here (`NULL`), the values are taken from the underlying model
29-
#' functions. If parameters need to be modified, `update()` can be used
29+
#' functions. If parameters need to be modified, `update()` can be used
3030
#' in lieu of recreating the object from scratch.
3131
#'
3232
#' @param mode A single character string for the type of model.
@@ -38,18 +38,18 @@
3838
#' @param trees An integer for the number of trees contained in
3939
#' the ensemble.
4040
#' @param min_n An integer for the minimum number of data points
41-
#' in a node that are required for the node to be split further.
41+
#' in a node that is required for the node to be split further.
4242
#' @param tree_depth An integer for the maximum depth of the tree (i.e. number
4343
#' of splits) (`xgboost` only).
4444
#' @param learn_rate A number for the rate at which the boosting algorithm adapts
4545
#' from iteration-to-iteration (`xgboost` only).
4646
#' @param loss_reduction A number for the reduction in the loss function required
47-
#' to split further (`xgboost` only).
47+
#' to split further (`xgboost` only).
4848
#' @param sample_size A number for the number (or proportion) of data that is
49-
#' exposed to the fitting routine. For `xgboost`, the sampling is done at at
49+
#' exposed to the fitting routine. For `xgboost`, the sampling is done at
5050
#' each iteration while `C5.0` samples once during training.
5151
#' @param stop_iter The number of iterations without improvement before
52-
#' stopping (`xgboost` only).
52+
#' stopping (`xgboost` only).
5353
#' @details
5454
#' The data given to the function are not saved and are only used
5555
#' to determine the _mode_ of the model. For `boost_tree()`, the
@@ -58,7 +58,7 @@
5858
#' The model can be created using the `fit()` function using the
5959
#' following _engines_:
6060
#' \itemize{
61-
#' \item \pkg{R}: `"xgboost"` (the default), `"C5.0"`
61+
#' \item \pkg{R}: `"xgboost"` (the default), `"C5.0"`
6262
#' \item \pkg{Spark}: `"spark"`
6363
#' }
6464
#'
@@ -278,7 +278,7 @@ check_args.boost_tree <- function(object) {
278278
#' of training set samples use for these purposes.
279279
#' @param early_stop An integer or `NULL`. If not `NULL`, it is the number of
280280
#' training iterations without improvement before stopping. If `validation` is
281-
#' used, performance is base on the validation set; otherwise the training set
281+
#' used, performance is base on the validation set; otherwise, the training set
282282
#' is used.
283283
#' @param ... Other options to pass to `xgb.train`.
284284
#' @return A fitted `xgboost` object.

R/decision_tree.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
#' that are required for the node to be split further.
1616
#' }
1717
#' These arguments are converted to their specific names at the
18-
#' time that the model is fit. Other options and argument can be
18+
#' time that the model is fit. Other options and arguments can be
1919
#' set using `set_engine()`. If left to their defaults
2020
#' here (`NULL`), the values are taken from the underlying model
2121
#' functions. If parameters need to be modified, `update()` can be used
@@ -34,7 +34,7 @@
3434
#' The model can be created using the `fit()` function using the
3535
#' following _engines_:
3636
#' \itemize{
37-
#' \item \pkg{R}: `"rpart"` (the default) or `"C5.0"` (classification only)
37+
#' \item \pkg{R}: `"rpart"` (the default) or `"C5.0"` (classification only)
3838
#' \item \pkg{Spark}: `"spark"`
3939
#' }
4040
#'
@@ -206,7 +206,7 @@ check_args.decision_tree <- function(object) {
206206
#' this means that the overall R-squared must increase by `cp` at
207207
#' each step. The main role of this parameter is to save computing
208208
#' time by pruning off splits that are obviously not worthwhile.
209-
#' Essentially,the user informs the program that any split which
209+
#' Essentially, the user informs the program that any split which
210210
#' does not improve the fit by `cp` will likely be pruned off by
211211
#' cross-validation, and that hence the program need not pursue it.
212212
#' @param weights Optional case weights.

R/descriptors.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010
#' Existing functions:
1111
#' \itemize{
1212
#' \item `.obs()`: The current number of rows in the data set.
13-
#' \item `.preds()`: The number of columns in the data set that are
13+
#' \item `.preds()`: The number of columns in the data set that is
1414
#' associated with the predictors prior to dummy variable creation.
1515
#' \item `.cols()`: The number of predictor columns available after dummy
1616
#' variables are created (if any).
17-
#' \item `.facts()`: The number of factor predictors in the dat set.
17+
#' \item `.facts()`: The number of factor predictors in the data set.
1818
#' \item `.lvls()`: If the outcome is a factor, this is a table
1919
#' with the counts for each level (and `NA` otherwise).
2020
#' \item `.x()`: The predictors returned in the format given. Either a

R/fit.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@
2424
#' ignored. Other options required to fit the model should be
2525
#' passed using `set_engine()`.
2626
#' @details `fit()` and `fit_xy()` substitute the current arguments in the model
27-
#' specification into the computational engine's code, checks them
28-
#' for validity, then fits the model using the data and the
27+
#' specification into the computational engine's code, check them
28+
#' for validity, then fit the model using the data and the
2929
#' engine-specific code. Different model functions have different
3030
#' interfaces (e.g. formula or `x`/`y`) and these functions translate
31-
#' between the interface used when `fit()` or `fit_xy()` were invoked and the one
31+
#' between the interface used when `fit()` or `fit_xy()` was invoked and the one
3232
#' required by the underlying model.
3333
#'
3434
#' When possible, these functions attempt to avoid making copies of the

R/linear_reg.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#' regularization (see below). Note that this will be ignored for some engines.
1212
#' }
1313
#' These arguments are converted to their specific names at the
14-
#' time that the model is fit. Other options and argument can be
14+
#' time that the model is fit. Other options and arguments can be
1515
#' set using `set_engine()`. If left to their defaults
1616
#' here (`NULL`), the values are taken from the underlying model
1717
#' functions. If parameters need to be modified, `update()` can be used

R/logistic_reg.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#' regularization (see below). Note that this will be ignored for some engines.
1212
#' }
1313
#' These arguments are converted to their specific names at the
14-
#' time that the model is fit. Other options and argument can be
14+
#' time that the model is fit. Other options and arguments can be
1515
#' set using `set_engine()`. If left to their defaults
1616
#' here (`NULL`), the values are taken from the underlying model
1717
#' functions. If parameters need to be modified, `update()` can be used

R/mars.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@
1010
#' \item \code{num_terms}: The number of features that will be retained in the
1111
#' final model.
1212
#' \item \code{prod_degree}: The highest possible degree of interaction between
13-
#' features. A value of 1 indicates and additive model while a value of 2
13+
#' features. A value of 1 indicates an additive model while a value of 2
1414
#' allows, but does not guarantee, two-way interactions between features.
1515
#' \item \code{prune_method}: The type of pruning. Possible values are listed
1616
#' in `?earth`.
1717
#' }
1818
#' These arguments are converted to their specific names at the
19-
#' time that the model is fit. Other options and argument can be
19+
#' time that the model is fit. Other options and arguments can be
2020
#' set using `set_engine()`. If left to their defaults
2121
#' here (`NULL`), the values are taken from the underlying model
2222
#' functions. If parameters need to be modified, `update()` can be used

R/mlp.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#' }
1818
#'
1919
#' These arguments are converted to their specific names at the
20-
#' time that the model is fit. Other options and argument can be
20+
#' time that the model is fit. Other options and arguments can be
2121
#' set using `set_engine()`. If left to their defaults
2222
#' here (see above), the values are taken from the underlying model
2323
#' functions. One exception is `hidden_units` when `nnet::nnet` is used; that

R/model_object_docs.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#' The main elements of the object are:
88
#'
99
#' * `args`: A vector of the main arguments for the model. The
10-
#' names of these arguments may be different form their
10+
#' names of these arguments may be different from their
1111
#' counterparts n the underlying model function. For example, for a
1212
#' `glmnet` model, the argument name for the amount of the penalty
1313
#' is called "penalty" instead of "lambda" to make it more general
@@ -146,7 +146,7 @@ NULL
146146
#' The main elements of the object are:
147147
#'
148148
#' * `lvl`: A vector of factor levels when the outcome is
149-
#' is a factor. This is `NULL` when the outcome is not a factor
149+
#' a factor. This is `NULL` when the outcome is not a factor
150150
#' vector.
151151
#'
152152
#' * `spec`: A `model_spec` object.
@@ -169,7 +169,7 @@ NULL
169169
#' specification.
170170
#'
171171
#' This class and structure is the basis for how \pkg{parsnip}
172-
#' stores model objects after to seeing the data and applying a model.
172+
#' stores model objects after seeing the data and applying a model.
173173
#' @rdname model_fit
174174
#' @name model_fit
175175
#' @examples

R/multinom_reg.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#' regularization (see below). Note that this will be ignored for some engines.
1212
#' }
1313
#' These arguments are converted to their specific names at the
14-
#' time that the model is fit. Other options and argument can be
14+
#' time that the model is fit. Other options and arguments can be
1515
#' set using `set_engine()`. If left to their defaults
1616
#' here (`NULL`), the values are taken from the underlying model
1717
#' functions. If parameters need to be modified, `update()` can be used

R/nearest_neighbor.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
#' and the Euclidean distance with `dist_power = 2`.
1919
#' }
2020
#' These arguments are converted to their specific names at the
21-
#' time that the model is fit. Other options and argument can be
21+
#' time that the model is fit. Other options and arguments can be
2222
#' set using `set_engine()`. If left to their defaults
2323
#' here (`NULL`), the values are taken from the underlying model
2424
#' functions. If parameters need to be modified, `update()` can be used

R/nullmodel.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
#' the training samples with that class (the other columns are zero). } \item{n
3030
#' }{the number of elements in \code{y}}
3131
#'
32-
#' `predict.nullmodel()` returns a either a factor or numeric vector
32+
#' `predict.nullmodel()` returns either a factor or numeric vector
3333
#' depending on the class of \code{y}. All predictions are always the same.
3434
#' @keywords models
3535
#' @examples

R/predict_interval.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#' @rdname other_predict
33
#' @param level A single numeric value between zero and one for the
44
#' interval estimates.
5-
#' @param std_error A single logical for wether the standard error should be
5+
#' @param std_error A single logical for whether the standard error should be
66
#' returned (assuming that the model can compute it).
77
#' @inheritParams predict.model_fit
88
#' @method predict_confint model_fit

R/surv_reg.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#' \item \code{dist}: The probability distribution of the outcome.
99
#' }
1010
#' This argument is converted to its specific names at the
11-
#' time that the model is fit. Other options and argument can be
11+
#' time that the model is fit. Other options and arguments can be
1212
#' set using `set_engine()`. If left to its default
1313
#' here (`NULL`), the value is taken from the underlying model
1414
#' functions.

R/svm_poly.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#' (regression only)
1414
#' }
1515
#' These arguments are converted to their specific names at the
16-
#' time that the model is fit. Other options and argument can be
16+
#' time that the model is fit. Other options and arguments can be
1717
#' set using `set_engine()`. If left to their defaults
1818
#' here (`NULL`), the values are taken from the underlying model
1919
#' functions. If parameters need to be modified, `update()` can be used
@@ -28,7 +28,7 @@
2828
#' @param degree A positive number for polynomial degree.
2929
#' @param scale_factor A positive number for the polynomial scaling factor.
3030
#' @param margin A positive number for the epsilon in the SVM insensitive
31-
#' loss function (regression only)
31+
#' loss function (regression only)
3232
#' @details
3333
#' The model can be created using the `fit()` function using the
3434
#' following _engines_:

R/svm_rbf.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#' (regression only)
1414
#' }
1515
#' These arguments are converted to their specific names at the
16-
#' time that the model is fit. Other options and argument can be
16+
#' time that the model is fit. Other options and arguments can be
1717
#' set using `set_engine()`. If left to their defaults
1818
#' here (`NULL`), the values are taken from the underlying model
1919
#' functions. If parameters need to be modified, `update()` can be used
@@ -27,7 +27,7 @@
2727
#' or on the wrong side of the margin
2828
#' @param rbf_sigma A positive number for radial basis function.
2929
#' @param margin A positive number for the epsilon in the SVM insensitive
30-
#' loss function (regression only)
30+
#' loss function (regression only)
3131
#' @details
3232
#' The model can be created using the `fit()` function using the
3333
#' following _engines_:

man/boost_tree.Rd

Lines changed: 9 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/decision_tree.Rd

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/descriptors.Rd

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/fit.Rd

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/linear_reg.Rd

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)