Home > Blockchain >  Calculation of geometric fold error calculation in R
Calculation of geometric fold error calculation in R

Time:09-29

Hi I have created a dummy data set, I want to calculate geometric mean fold error between the obs/pred values of the model in R. Kindly help thanks

a=c(1,2,4,2,5,6,3,2,6,8,10,4) 

b=c(1.3,3.2,4.4,2.5,1.6,4.5,5.5,2.2,3.1,6.4,3.0,6.3)

n= cbind(a,b)
m=data.frame(n)
names(m)[1]<-paste("Observed M/P")
names(m)[2]<-paste("Predicted M/P")

CodePudding user response:

according to the bellow ref

10.1002/psp4.12646 (page 7)

what you are looking should be something like

GMFE = 10^(sum(abs(log(b/a)))/length(a)) 

GMFE below 2 indicates a good prediction!

Hope this will help

  • Related