etiennebacher / tennistravel

Shiny app for the Shiny Contest 2021: find out the carbon footprint of tennis players.
Other
0 stars 0 forks source link

need to make the computations faster, especially for footprint #1

Closed etiennebacher closed 3 years ago

etiennebacher commented 3 years ago
microbenchmark::microbenchmark(
  dist_player_year("Nadal", 2015),
  footprint_player_year("Nadal", 2015),
  times = 50
)

Unit: milliseconds
                                 expr      min       lq     mean   median       uq
      dist_player_year("Nadal", 2015) 108.9135 109.8896 113.5125 111.3189 116.3803
 footprint_player_year("Nadal", 2015) 169.3256 171.7981 177.9725 174.3231 179.2912
      max neval
 128.2049    50
 250.1617    50

Use data.table?