CommencerCommencer gratuitement

Benchmark DataCamp's machine

The benchmarkme package allows you to run a set of standardized benchmarks and compare your results to other users. One set of benchmarks tests is reading and writing speeds.

The function call

res = benchmark_io(runs = 1, size = 5)

records the length of time it takes to read and write a 5MB file.

Cet exercice fait partie du cours

Writing Efficient R Code

Afficher le cours

Instructions

  • Find the time it takes to read and write a 5 MB file. Assign the result to res. (Do not attempt to read and write a 50 MB file. Your session on DataCamp may crash)
  • Compare DataCamp to other users via plot(res).

Exercice interactif pratique

Essayez cet exercice en complétant cet exemple de code.

# Load the package
library("benchmarkme")

# Run the io benchmark
res <- ___(runs = 1, size = ___)

# Plot the results
___
Modifier et exécuter le code