learn: Learn

View source: R/learn.R

learnR Documentation

Learn

Description

Create or update a Probabilist neural network.

Usage

  learn(set, nn, category.column = 1)

Arguments

set

Data frame representing the training set. The first column is used to define the category of each observation (set category.column if it is not the case).

nn

A Probabilistic neural network with or without training.

category.column

The field number of the category (1 by default).

Details

The function learn aims to create a new Probabilist neural network with a training set, or update the training set of an already trained Probabilist neural network. It sets the parameters model, set, category.column, categories, k and n of the neural network.

Value

A trained Probabilist neural network.

See Also

pnn-package, smooth, perf, guess, norms

Examples

library(pnn)
data(norms)
pnn <- learn(norms)
pnn$model
pnn$set[1:10,]
pnn$category.column
pnn$categories
pnn$k
pnn$n

chasset/pnn documentation built on March 24, 2022, 7 a.m.