Unverified Commit 3d8013c8 authored by Axel Durand's avatar Axel Durand Committed by GitHub
Browse files

[python-package] [docs] Expand class docs for Dataset (#6558)

parent cbee5eea
...@@ -63,4 +63,4 @@ Imports: ...@@ -63,4 +63,4 @@ Imports:
utils utils
SystemRequirements: SystemRequirements:
~~CXXSTD~~ ~~CXXSTD~~
RoxygenNote: 7.3.1 RoxygenNote: 7.3.2
...@@ -758,8 +758,13 @@ Dataset <- R6::R6Class( ...@@ -758,8 +758,13 @@ Dataset <- R6::R6Class(
) )
#' @title Construct \code{lgb.Dataset} object #' @title Construct \code{lgb.Dataset} object
#' @description Construct \code{lgb.Dataset} object from dense matrix, sparse matrix #' @description LightGBM does not train on raw data.
#' or local file (that was created previously by saving an \code{lgb.Dataset}). #' It discretizes continuous features into histogram bins, tries to
#' combine categorical features, and automatically handles missing and
# infinite values.
#'
#' The \code{Dataset} class handles that preprocessing, and holds that
#' alternative representation of the input data.
#' @inheritParams lgb_shared_dataset_params #' @inheritParams lgb_shared_dataset_params
#' @param data a \code{matrix} object, a \code{dgCMatrix} object, #' @param data a \code{matrix} object, a \code{dgCMatrix} object,
#' a character representing a path to a text file (CSV, TSV, or LibSVM), #' a character representing a path to a text file (CSV, TSV, or LibSVM),
......
...@@ -60,8 +60,12 @@ second group, etc.} ...@@ -60,8 +60,12 @@ second group, etc.}
constructed dataset constructed dataset
} }
\description{ \description{
Construct \code{lgb.Dataset} object from dense matrix, sparse matrix LightGBM does not train on raw data.
or local file (that was created previously by saving an \code{lgb.Dataset}). It discretizes continuous features into histogram bins, tries to
combine categorical features, and automatically handles missing and
The \code{Dataset} class handles that preprocessing, and holds that
alternative representation of the input data.
} }
\examples{ \examples{
\donttest{ \donttest{
......
...@@ -12,7 +12,7 @@ dependencies: ...@@ -12,7 +12,7 @@ dependencies:
- r-markdown=1.12 - r-markdown=1.12
- r-matrix=1.6_4 - r-matrix=1.6_4
- r-pkgdown=2.0.7 - r-pkgdown=2.0.7
- r-roxygen2=7.3.1 - r-roxygen2=7.3.2
- scikit-learn>=1.4.0 - scikit-learn>=1.4.0
- sphinx>=6.0 - sphinx>=6.0
- sphinx_rtd_theme>=2.0 - sphinx_rtd_theme>=2.0
...@@ -1745,7 +1745,15 @@ class _InnerPredictor: ...@@ -1745,7 +1745,15 @@ class _InnerPredictor:
class Dataset: class Dataset:
"""Dataset in LightGBM.""" """
Dataset in LightGBM.
LightGBM does not train on raw data.
It discretizes continuous features into histogram bins, tries to combine categorical features,
and automatically handles missing and infinite values.
This class handles that preprocessing, and holds that alternative representation of the input data.
"""
def __init__( def __init__(
self, self,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment