Loops size estimates vectorized (solution)

Exercise
Output solution

Code solution for Use and Modify with Apply

Part 1

 [1]  25262.027  41253.332  10767.568  95233.732 101260.017  40775.516
 [7]  24072.130   4785.145  39129.521  29666.193  26830.297  64700.869
[13]  42768.180  94697.262  79013.471 103955.226  92798.465  41901.983
[19]  17439.569  41055.045  37544.201  25198.303  12928.490  36388.290
[25]  34962.862  80307.929   8854.525  50183.194  28846.165  35735.369
[31] 115908.187  31765.368  58958.713   5561.862  28349.410  15418.314
[37]   9218.648   1197.666  94407.873  19552.500

Part 2

 [1]  26039.686  42825.603  10800.224  98273.049 104257.481  41822.386
 [7]  24840.644   4899.022  39915.948  30937.922  26354.908  66384.865
[13]  43837.944  97141.451  80553.856 105556.405  97374.660  42760.136
[19]  18749.274  42109.012  40674.182  26003.425  13229.824  37472.789
[25]  34684.033  80187.272   9460.977  51630.571  29253.772  36399.306
[31] 117511.962  33384.288  58581.226   5462.316  28637.745  15864.172
[37]   9284.810   1218.755  98522.609  19534.524

Part 3


Attaching package: 'dplyr'
The following objects are masked from 'package:stats':

    filter, lag
The following objects are masked from 'package:base':

    intersect, setdiff, setequal, union
   theropoda_lengths a_values b_values     masses
1          17.801363    0.759    3.627  26039.686
2          20.376445    0.751    3.633  42825.603
3          14.074349    0.740    3.626  10800.224
4          25.657824    0.746    3.633  98273.049
5          26.095201    0.759    3.627 104257.481
6          20.311154    0.751    3.629  41822.386
7          17.566324    0.749    3.632  24840.644
8          11.256343    0.751    3.628   4899.022
9          20.081903    0.738    3.633  39915.948
10         18.607163    0.768    3.627  30937.922
11         18.099189    0.736    3.621  26354.908
12         23.065969    0.749    3.630  66384.865
13         20.579885    0.746    3.631  43837.944
14         25.617925    0.744    3.632  97141.451
15         24.371433    0.749    3.628  80553.856
16         26.284725    0.751    3.626 105556.405
17         25.475378    0.744    3.639  97374.660
18         20.464209    0.754    3.626  42760.136
19         16.073826    0.774    3.635  18749.274
20         20.349417    0.751    3.629  42109.012
21         19.854399    0.763    3.642  40674.182
22         17.788981    0.749    3.632  26003.425
23         14.801642    0.741    3.633  13229.824
24         19.684091    0.754    3.629  37472.789
25         19.468589    0.746    3.620  34684.033
26         24.480778    0.755    3.619  80187.272
27         13.335996    0.764    3.638   9460.977
28         21.506599    0.758    3.627  51630.571
29         18.464030    0.760    3.621  29253.772
30         19.586153    0.748    3.628  36399.306
31         27.084752    0.745    3.628 117511.962
32         18.960937    0.756    3.635  33384.288
33         22.482917    0.739    3.624  58581.226
34         11.732572    0.733    3.621   5462.316
35         18.375885    0.757    3.621  28637.745
36         15.537505    0.747    3.632  15864.172
37         13.484875    0.741    3.627   9284.810
38          7.685612    0.752    3.624   1218.755
39         25.596335    0.752    3.634  98522.609
40         16.588285    0.748    3.621  19534.524