2020年7月28日火曜日

R 無限ループ



library(reshape2)
library(ggplot2)
library(audio)
for(i in seq(1,36,1)){
  source("../../Dropbox/R-script/covid/tokyo_effective_repro.r")
  # source("../../Dropbox/R-script/covid/em_region.r")
  # source("../../Dropbox/R-script/covid/tokyo_age_split.r")
  source("../../Dropbox/R-script/covid/plot_effective_repro.r")
  # source("../../Dropbox/R-script/covid/tokyo_vs_others.r")
  # source("../../Dropbox/R-script/covid/em_region.r")

  print(Sys.time())
{if(sum(mdf[(length(rownames(mdf))-6):length(rownames(mdf)),i])>1){cat(colnames(mdf)[i]);cat(" ");cat(sum(mdf[(length(rownames(mdf))-6):length(rownames(mdf)),i]));t <- t+sum(mdf[(length(rownames(mdf))-6):length(rownames(mdf)),i]) ;cat("\n")}};cat(paste("total ",t,"\n",sep=''))

  wait(3600)
}

0 件のコメント: