Learn R Programming

ParallelLogger (version 3.4.1)

stopCluster: Stop the cluster

Description

Stop the cluster

Usage

stopCluster(cluster)

Arguments

cluster

The cluster to stop

Examples

Run this code
fun <- function(x) {
  return (x^2)
}

cluster <- makeCluster(numberOfThreads = 3)
clusterApply(cluster, 1:10, fun)
stopCluster(cluster)

Run the code above in your browser using DataLab