Neural Networks with the package "AMORE" - R

3

Ladies and gentlemen, I'm trying to use the AMORE package of R to run a Neural Network with new activation functions, but I could not understand the manual very well and consequently I was not able to implement the new function. Anyway, the function I want to implement is as follows:

Ordonez

ord <- function(x){
   1-((1+0.5*exp(x))^(-1/0.5))#activation function Aranda-Ordonez
}

DERIVATIVE Ordonez

dord <- function(x){
   ((1+0.5*exp(x))^(-(1+0.5)/0.5))*exp(x)# derivative activation functionao Aranda-Ordonez
}

and the function of the R that I want to use is this, which I just want to modify the function of the last neuron output.layer="custom" :

select.activation.function(activation.function)

library(AMORE)

P <- matrix(sample(seq(-1,1,length=1000), 1000, replace=FALSE), ncol=1)

target <- P^2

net <- newff(n.neurons=c(1,3,2,1), learning.rate.global=1e-2, momentum.global=0.5,
error.criterium="LMS", Stao=NA, hidden.layer="tansig",
output.layer="custom", method="ADAPTgdwm")
result <- train(net, P, target, error.criterium="LMS", report=TRUE, show.step=100, n.shows=5 )


y <- sim(result$net, P)

If someone has already used or has any tips to give me, I am grateful for the help.

Sincerely, Elisalvo

    
asked by anonymous 12.12.2014 / 23:51

1 answer

-1

I was able to implement neural networks with the neuralnet package following this tutorial: link

This package seemed simple to implement. I also tried the package RNNS but without success.

Here's also a list of tutorials: link

If you adopt the neuralnet package and you have any questions, I can help you more. The package AMORE never used.

    
27.02.2018 / 12:54