Learn R Programming

sits (version 0.13.0)

sits_train: Train sits classification models

Description

Given a tibble with a set of distance measures, returns trained models. Currenly, sits supports the following models: 'svm' (see sits_svm), random forests (see sits_rfor), linear discriminant analysis (see sits_lda), quadratic discriminant analysis (see sits_qda), multinomial logit (see sits_mlr) and its variants 'lasso' (see sits_mlr) and 'ridge' (see sits_mlr), extreme gradient boosting (see sits_xgboost), and different deep learning functions, including multi-layer perceptrons (see sits_mlp), 1D convolution neural networks sits_TempCNN, and a deep Residual Network sits_ResNet.

Usage

sits_train(data, ml_method = sits_svm())

Arguments

data

Time series with the training samples.

ml_method

Machine learning method.

Value

Model fitted to input data to be passed to sits_classify

Examples

Run this code
# NOT RUN {
# Retrieve the set of samples for Mato Grosso (provided by EMBRAPA)
# fit a training model (RFOR model)
samples <- sits_select(samples_mt_6bands, bands = c("NDVI"))
ml_model <- sits_train(samples, sits_rfor(num_trees = 100))
# get a point and classify the point with the ml_model
point_ndvi <- sits_select(point_mt_6bands, bands = "NDVI")
class <- sits_classify(point_ndvi, ml_model)

# }

Run the code above in your browser using DataLab