a <- foreach(z=z, .combine='rbind') %dopar% func(x, y, z) a <- sum(a) stopCluster(cl) end <- (proc.time())[3][[1]] print(paste('Result = ', round(a, 2), ', time = ', (end-start), 's', sep='')) 輸出: [1] "Result = 96.72, time = 37.988s" 總結(jié) 1、...
www.dbjr.com.cn/article/2102...htm 2025-5-18