ECharm_Info=function(solution="1:2.5"){
  fromServer2=("https://docs.google.com/spreadsheets/d/e/2PACX-1vTRcGLaM3PyMDB0abd8r1VE0OW6TWQ5QzrINjW00oiwS_SYBXM2RIJhqw9hnAeP9ePATdix7HyDjgda/pub?output=csv")
  fromServer2.5=("https://docs.google.com/spreadsheets/d/e/2PACX-1vRs69jpFKSO-t-iCJAL_5Y76H6N1s39XXBQcgTDx9cZ6N0chf1fI13FkxiaQYLX2n-34wEqOQSTTTTb/pub?output=csv")
  fromServer5=("https://docs.google.com/spreadsheets/d/e/2PACX-1vQBDSv0JeMNwIevV4BgnhKCrsSG_EcseHxPxGCNAgMSAN1ikMg88mb7r05KCP7HEopna-J1Jkb3BjNO/pub?output=csv")

  # Illustrate predictive performance
  plotf=function(x){
    inputInfo = read.csv(x)
    df1=as.matrix(inputInfo[,2:ncol(inputInfo)])
    row.names(df1)=c("Africa","N.America","Asia","Europe","LAC","NENA","Pacific")
    regioncol=c("blue","red","cyan","magenta","green","gray", "yellow")
    par(mgp=c(3,0.6,0),mar=c(5,4.5,1,1)+0.1)
    barplot(df1, las=2,beside = TRUE,xpd = FALSE,col=regioncol,ylim=c(0,1.2),horiz = FALSE, cex.names = 0.75,space = c(0.4, 4))
    grid (nx=NA, ny=NULL, lty = 6, col = "gray")
    legend("topleft", x.intersp=0.25,y.intersp=0,bg="transparent",text.width=11,legend = rownames(df1), fill = regioncol, box.lty = 0, cex = 0.6, horiz = TRUE)
    box(lty = 1, col = 'black')
    mtext(side=1, text="EC harmonization models", line=3.7)
    mtext(side=2, text="Performance index", line=2.5)
  }
  # Check internet
  get_info=function(x){
    if(is.null(checkInternet(x))){
      #stop("Stoping execution",.Call=FALSE)
      withr::with_options(
        list(show.error.messages = FALSE),
        {
          print("Internet connectivity to server is needed")
          stop(x)
        }
      )
    }
    plotf(x)
  }
  if(solution=="1:2"){
    get_info(fromServer2)
  }
  else if(solution == "1:2.5"){
    get_info(fromServer2.5)
  }
  else if(solution == "1:5"){
    get_info(fromServer5)
  }
}
