anfis (version 0.99.1)

trainSet: Bidimentional Sinc train set example

Description

Generates the training set of sinc(x)*sinc(y) for the (x,y) regular grid

Usage

trainSet(x, y)

Arguments

x
numeric vector with the x-th grid coordinates
y
numeric vector with the x-th grid coordinates

Value

matrix
numeric matrix with the columns x, y and z=sync(x,y)

See Also

Other ANFIS: ANFIS-class; LSE, LSE, LSE,ANFIS-method, LSE-methods, trainHybridJangOffLine, trainHybridJangOffLine, trainHybridJangOffLine,ANFIS-method, trainHybridJangOffLine-methods, trainHybridJangOnLine, trainHybridJangOnLine, trainHybridJangOnLine,ANFIS-method, trainHybridJangOnLine-methods, trainHybridOffLine, trainHybridOffLine, trainHybridOffLine,ANFIS-method, trainHybridOffLine-methods; anfis3; coef, coef,ANFIS-method, coefficients, coefficients,ANFIS-method, fitted, fitted,ANFIS-method, fitted.values, fitted.values,ANFIS-method, resid, resid,ANFIS-method, residuals, residuals,ANFIS-method, summary, summary,ANFIS-method; getConsequents, getConsequents, getConsequents,ANFIS-method, getConsequents,ANFIS-method, getErrors, getErrors, getErrors,ANFIS-method, getErrors,ANFIS-method, getPremises, getPremises, getPremises,ANFIS-method, getPremises-methods, getRules, getRules, getRules,ANFIS-method, getRules-methods, getTrainingType, getTrainingType, getTrainingType,ANFIS-method, getTrainingType,ANFIS-method; initialize, initialize,ANFIS-method; plotMF, plotMF, plotMF,ANFIS-method, plotMF-methods, plotMFs, plotMFs, plotMFs,ANFIS-method, plotMFs-methods; plot, plot,ANFIS-method; predict, predict,ANFIS-method; print, print,ANFIS-method, show, show,ANFIS-method

Examples

Run this code
##Domain definition for a regular (x,y) grid with 11 points for each
##coordinates
x <- seq(-10, 10, length= 11)
trainingSet <- trainSet(x,x)
Z <- matrix(trainingSet[,"z"],ncol=length(x),nrow=length(x))

##Plot the domain
persp(x, x, Z, theta=45, phi=15, expand=0.8, col="lightblue",
 ticktype="detailed", main="sinc(x)*sinc(y)")

Run the code above in your browser using DataLab