This function queries the given database to retrieve data on deadwood (logs) (ready for use in calculate_dendrometry() function).

load_data_deadwood(
  database,
  plottype = NA,
  forest_reserve = NA,
  extra_variables = FALSE,
  processed = TRUE
)

Arguments

database

name of Fieldmap/Access database (with specific Fieldmap structure) including path

plottype

possibility to select only data for a certain plot type, e.g. 'CP' for Circular plot or 'CA' for Core area (the default NA means that data from all plots are retrieved)

forest_reserve

possibility to select only data for 1 forest reserve by giving the name of the forest reserve (the default NA means that data from all plots are retrieved)

extra_variables

Should additional variables such as remark and common_remark be added? Default is FALSE (no).

processed

Should only processed and surveyed data be added? Defaults to TRUE (yes).

Value

Dataframe with data on logs

Examples

library(forrescalc)
# (add path to your own fieldmap database here)
path_to_fieldmapdb <-
  system.file("example/database/mdb_bosres.sqlite", package = "forrescalc")
load_data_deadwood(path_to_fieldmapdb)
#>      forest_reserve plot_id plottype period year date_dendro totalplotarea_ha
#> 1      Everzwijnbad     101       CP      1 2002  2002-12-01        0.1017876
#> 2      Everzwijnbad     101       CP      1 2002  2002-12-01        0.1017876
#> 3      Everzwijnbad     101       CP      1 2002  2002-12-01        0.1017876
#> 4      Everzwijnbad     101       CP      1 2002  2002-12-01        0.1017876
#> 5   Withoefse heide     204       CP      1 2000  2000-07-01        0.1257000
#> 6   Withoefse heide     204       CP      1 2000  2000-07-01        0.1257000
#> 7   Withoefse heide     204       CP      1 2000  2000-07-01        0.1257000
#> 8        Liedekerke    1005       CP      1 2006  2007-01-01        0.0706858
#> 9            Harras   21000       CA      1 2008  2009-03-01        0.9800008
#> 10           Harras   21000       CA      1 2008  2009-03-01        0.9800008
#> 11           Harras   21000       CA      1 2008  2009-03-01        0.9800008
#> 12           Harras   21000       CA      1 2008  2009-03-01        0.9800008
#> 13           Harras   21000       CA      1 2008  2009-03-01        0.9800008
#> 14           Harras   21000       CA      1 2008  2009-03-01        0.9800008
#> 15     Sevendonck A  141100       CA      1 2007  2007-10-01        0.4989261
#> 16     Sevendonck A  141100       CA      1 2007  2007-10-01        0.4989261
#> 17     Sevendonck A  141100       CA      1 2007  2007-10-01        0.4989261
#> 18     Everzwijnbad     101       CP      2 2012  2013-01-10        0.1017876
#> 19     Everzwijnbad     101       CP      2 2012  2013-01-10        0.1017876
#> 20     Everzwijnbad     101       CP      2 2012  2013-01-10        0.1017876
#> 21     Everzwijnbad     101       CP      2 2012  2013-01-10        0.1017876
#> 22     Everzwijnbad     101       CP      2 2012  2013-01-10        0.1017876
#> 23  Withoefse heide     204       CP      2 2011  2012-03-01        0.1257000
#> 24  Withoefse heide     204       CP      2 2011  2012-03-01        0.1257000
#> 25  Withoefse heide     204       CP      2 2011  2012-03-01        0.1257000
#> 26 Kersselaerspleyn    2006       CP      2 2010  2010-06-17        0.2827000
#> 27 Kersselaerspleyn    2006       CP      2 2010  2010-06-17        0.2827000
#> 28 Kersselaerspleyn    2006       CP      2 2010  2010-06-17        0.2827000
#> 29 Kersselaerspleyn    2006       CP      2 2010  2010-06-17        0.2827000
#> 30 Kersselaerspleyn    2006       CP      2 2010  2010-06-17        0.2827000
#> 31 Kersselaerspleyn    2006       CP      2 2010  2010-06-17        0.2827000
#> 32 Kersselaerspleyn   11000       CA      2 2010  2010-06-01       10.7485378
#> 33 Kersselaerspleyn   11000       CA      2 2010  2010-06-01       10.7485378
#> 34 Kersselaerspleyn   11000       CA      2 2010  2010-06-01       10.7485378
#> 35 Kersselaerspleyn   11000       CA      2 2010  2010-06-01       10.7485378
#> 36 Kersselaerspleyn   11000       CA      2 2010  2010-06-01       10.7485378
#> 37 Kersselaerspleyn   11000       CA      2 2010  2010-06-01       10.7485378
#> 38           Harras   21000       CA      2 2018  2018-09-03        0.9800008
#> 39           Harras   21000       CA      2 2018  2018-09-03        0.9800008
#> 40           Harras   21000       CA      2 2018  2018-09-03        0.9800008
#> 41           Harras   21000       CA      2 2018  2018-09-03        0.9800008
#> 42           Harras   21000       CA      2 2018  2018-09-03        0.9800008
#> 43           Harras   21000       CA      2 2018  2018-09-03        0.9800008
#> 44     Sevendonck A  141100       CA      2 2016  2017-02-06        0.4989261
#> 45     Sevendonck A  141100       CA      2 2016  2017-02-06        0.4989261
#> 46     Sevendonck A  141100       CA      2 2016  2017-02-06        0.4989261
#> 47     Sevendonck A  141100       CA      2 2016  2017-02-06        0.4989261
#> 48 Kersselaerspleyn    2006       CP      3 2020  2020-12-03        0.2827000
#> 49 Kersselaerspleyn    2006       CP      3 2020  2020-12-03        0.2827000
#> 50 Kersselaerspleyn    2006       CP      3 2020  2020-12-03        0.2827000
#> 51 Kersselaerspleyn    2006       CP      3 2020  2020-12-03        0.2827000
#> 52 Kersselaerspleyn    2006       CP      3 2020  2020-12-03        0.2827000
#> 53 Kersselaerspleyn    2006       CP      3 2020  2020-12-03        0.2827000
#> 54 Kersselaerspleyn   11000       CA      3 2020  2020-09-11       10.7485378
#> 55 Kersselaerspleyn   11000       CA      3 2020  2020-09-11       10.7485378
#> 56 Kersselaerspleyn   11000       CA      3 2020  2020-09-11       10.7485378
#> 57 Kersselaerspleyn   11000       CA      3 2020  2020-09-11       10.7485378
#> 58 Kersselaerspleyn   11000       CA      3 2020  2020-09-11       10.7485378
#> 59 Kersselaerspleyn   11000       CA      3 2020  2020-09-11       10.7485378
#>    plotarea_ha lying_deadw_id species decaystage intact_fragm calc_volume_m3
#> 1   0.10178760          11587      87         12           20       0.010111
#> 2   0.10178760          11626      87         13           20       0.051150
#> 3   0.10178760          11629      16         13           20       0.028642
#> 4   0.10178760          21595      87         10           20       0.026293
#> 5   0.12566371           4652      26         13           20       0.031397
#> 6   0.12566371           4654      26         13           20       0.132376
#> 7   0.12566371           4656      26         13           20       0.065287
#> 8   0.07068583            256      87         13           20       0.125215
#> 9   0.98000000              1      87         13           20       0.070122
#> 10  0.98000000              2      87         13           20       0.091488
#> 11  0.98000000              3      87         13           20       0.044860
#> 12  0.98000000              4      16         13           20       0.096259
#> 13  0.98000000             37      16         14           20       2.239566
#> 14  0.98000000             38      16         13           20       0.028375
#> 15  0.50000000             48      87         13           20       0.046782
#> 16  0.50000000             50      87         12           20       0.157460
#> 17  0.50000000             51      87         13           20       0.037550
#> 18  0.10178760              1      87         13           20       0.025009
#> 19  0.10178760              2      16         12           20       0.072072
#> 20  0.10178760              3      16         12           20       0.125457
#> 21  0.10178760              4      87         11           20       0.022424
#> 22  0.10178760              5      87         13           20       0.039200
#> 23  0.12566371              1      26         14           20       0.024953
#> 24  0.12566371              2      26         13           20       0.075955
#> 25  0.12566371              3      26         13           20       0.229073
#> 26  0.28274334              1       7         14           20       0.054496
#> 27  0.28274334              2       7         14           20       0.017654
#> 28  0.28274334              3      87         13           20       0.023561
#> 29  0.28274334              4      87         13           20       0.067066
#> 30  0.28274334              5      87         13           20       0.793940
#> 31  0.28274334              6       7         15           20       0.012059
#> 32 10.74850000            496       7         14           20       2.168861
#> 33 10.74850000            497       7         14           20       5.337756
#> 34 10.74850000            498       7         14           20       6.451706
#> 35 10.74850000            687      87         13           10       3.127788
#> 36 10.74850000            699      87         13           20       2.452648
#> 37 10.74850000            701      87         11           10       6.635353
#> 38  0.98000000              1      87         10           20       0.248578
#> 39  0.98000000              2      87         10           20       0.012389
#> 40  0.98000000              3      87         10           20       0.016299
#> 41  0.98000000             18      16         10           20       0.269896
#> 42  0.98000000             26      16         14           20       0.028582
#> 43  0.98000000           1002      16         12           20       0.038932
#> 44  0.50000000              7       6         14           20       0.006062
#> 45  0.50000000              9      87         13           20       0.005201
#> 46  0.50000000             20      87         13           20       0.061579
#> 47  0.50000000             26      87         13           20       0.198267
#> 48  0.28274334              1       7         14           20       0.014511
#> 49  0.28274334              2      87         13           20       0.636307
#> 50  0.28274334              3       7         12           20       0.016680
#> 51  0.28274334              4      87         14           20       0.034024
#> 52  0.28274334              5       7         12           20       0.022437
#> 53  0.28274334              8      87         13           20       0.554639
#> 54 10.74850000            496       7         14           20       0.974255
#> 55 10.74850000            497       7         14           20       3.472722
#> 56 10.74850000            498       7         14           20       4.596163
#> 57 10.74850000            687      87         13           10       3.127788
#> 58 10.74850000            699      87         13           20       2.452139
#> 59 10.74850000            701      87         13           10       5.605822
#>    calc_length_m total_length_m min_diam_mm max_diam_mm dbh_class_5cm  r_A1
#> 1          1.287          3.283          10          10          <NA>  2.25
#> 2          5.368          5.368         100         120    10 - 15 cm  2.25
#> 3          8.226          8.255          10         110    10 - 15 cm  2.25
#> 4          4.760          4.760          10         140    10 - 15 cm  2.25
#> 5          5.312          5.312          10         145    10 - 15 cm 20.00
#> 6          9.713          9.712          10         223    20 - 25 cm 20.00
#> 7          9.593          9.593          10         156    15 - 20 cm 20.00
#> 8          5.171          5.171         150         200    20 - 25 cm  2.25
#> 9          5.368          8.754          70         250    25 - 30 cm    NA
#> 10         6.436          6.435          70         190    15 - 20 cm    NA
#> 11         3.825          3.825          80         160    15 - 20 cm    NA
#> 12         5.415          5.415         130         170    15 - 20 cm    NA
#> 13        17.631         17.632         220         560    55 - 60 cm    NA
#> 14         3.406          3.406          85         120    10 - 15 cm    NA
#> 15         5.271          5.654          90         120    10 - 15 cm    NA
#> 16         4.882         19.084          10         230    20 - 25 cm    NA
#> 17         0.948         19.089          10         230    20 - 25 cm    NA
#> 18         2.044          3.278          90         140    10 - 15 cm  2.25
#> 19         9.406         11.548          60         150    15 - 20 cm  2.25
#> 20        12.979         15.052          40         190    15 - 20 cm  2.25
#> 21         3.399          3.399          60         120    10 - 15 cm  2.25
#> 22         2.843          2.843          65         190    15 - 20 cm  2.25
#> 23         2.597          2.597          90         130    10 - 15 cm 20.00
#> 24         7.655          7.655          70         150    15 - 20 cm 20.00
#> 25         9.220          9.220         120         230    20 - 25 cm 20.00
#> 26         3.540          3.540         140         140    10 - 15 cm  3.00
#> 27         1.561          1.561         120         120    10 - 15 cm  3.00
#> 28         3.249          3.249          70         120    10 - 15 cm  3.00
#> 29         2.245          2.245         190         200    20 - 25 cm  3.00
#> 30        18.749         24.985         110         300    30 - 35 cm  3.00
#> 31         3.278         12.089          22         330    30 - 35 cm  3.00
#> 32        18.459         18.450         150         490    45 - 50 cm    NA
#> 33        15.984         15.984         560         740    70 - 75 cm    NA
#> 34        33.763         33.763         180         750    75 - 80 cm    NA
#> 35        30.563         30.563         130         550    55 - 60 cm    NA
#> 36        20.599         28.867         130         520    50 - 55 cm    NA
#> 37        34.048         34.048          80         820    80 - 85 cm    NA
#> 38         8.624          8.624          40         310    30 - 35 cm    NA
#> 39         4.263          4.263          10         100    10 - 15 cm    NA
#> 40         4.681          4.681          10         110    10 - 15 cm    NA
#> 41        16.184         16.184          70         210    20 - 25 cm    NA
#> 42         1.615          1.615         140         160    15 - 20 cm    NA
#> 43         7.868          7.868          30         120    10 - 15 cm    NA
#> 44         0.242          7.725          70         180    15 - 20 cm    NA
#> 45         0.340          4.882         120         140    10 - 15 cm    NA
#> 46         6.858          6.858          70         140    10 - 15 cm    NA
#> 47         9.926          9.926          90         220    20 - 25 cm    NA
#> 48         2.531          2.531          70         100    10 - 15 cm  3.00
#> 49        18.455         24.593          80         280    25 - 30 cm  3.00
#> 50         2.351          2.351          90         100    10 - 15 cm  3.00
#> 51         2.206          2.206         130         150    15 - 20 cm  3.00
#> 52         2.847          2.847          90         110    10 - 15 cm  3.00
#> 53        19.844         23.716          40         280    25 - 30 cm  3.00
#> 54         7.027          7.027         400         440    40 - 45 cm    NA
#> 55        15.984         15.984         330         700    70 - 75 cm    NA
#> 56        31.056         31.056         230         610    60 - 65 cm    NA
#> 57        30.563         30.563         130         550    55 - 60 cm    NA
#> 58        20.595         28.886         130         520    50 - 55 cm    NA
#> 59        34.048         34.048          80         750    75 - 80 cm    NA
#>    r_A2 r_A3 r_A4 length_core_area_m width_core_area_m core_area_ha
#> 1   4.5    9   18                 NA                NA           NA
#> 2   4.5    9   18                 NA                NA           NA
#> 3   4.5    9   18                 NA                NA           NA
#> 4   4.5    9   18                 NA                NA           NA
#> 5  20.0   20   20                 NA                NA           NA
#> 6  20.0   20   20                 NA                NA           NA
#> 7  20.0   20   20                 NA                NA           NA
#> 8   4.5   15   15                 NA                NA           NA
#> 9    NA   NA   NA                140                70       0.9800
#> 10   NA   NA   NA                140                70       0.9800
#> 11   NA   NA   NA                140                70       0.9800
#> 12   NA   NA   NA                140                70       0.9800
#> 13   NA   NA   NA                140                70       0.9800
#> 14   NA   NA   NA                140                70       0.9800
#> 15   NA   NA   NA                100                50       0.5000
#> 16   NA   NA   NA                100                50       0.5000
#> 17   NA   NA   NA                100                50       0.5000
#> 18  4.5    9   18                 NA                NA           NA
#> 19  4.5    9   18                 NA                NA           NA
#> 20  4.5    9   18                 NA                NA           NA
#> 21  4.5    9   18                 NA                NA           NA
#> 22  4.5    9   18                 NA                NA           NA
#> 23 20.0   20   20                 NA                NA           NA
#> 24 20.0   20   20                 NA                NA           NA
#> 25 20.0   20   20                 NA                NA           NA
#> 26  6.0   12   30                 NA                NA           NA
#> 27  6.0   12   30                 NA                NA           NA
#> 28  6.0   12   30                 NA                NA           NA
#> 29  6.0   12   30                 NA                NA           NA
#> 30  6.0   12   30                 NA                NA           NA
#> 31  6.0   12   30                 NA                NA           NA
#> 32   NA   NA   NA                 NA                NA      10.7485
#> 33   NA   NA   NA                 NA                NA      10.7485
#> 34   NA   NA   NA                 NA                NA      10.7485
#> 35   NA   NA   NA                 NA                NA      10.7485
#> 36   NA   NA   NA                 NA                NA      10.7485
#> 37   NA   NA   NA                 NA                NA      10.7485
#> 38   NA   NA   NA                140                70       0.9800
#> 39   NA   NA   NA                140                70       0.9800
#> 40   NA   NA   NA                140                70       0.9800
#> 41   NA   NA   NA                140                70       0.9800
#> 42   NA   NA   NA                140                70       0.9800
#> 43   NA   NA   NA                140                70       0.9800
#> 44   NA   NA   NA                100                50       0.5000
#> 45   NA   NA   NA                100                50       0.5000
#> 46   NA   NA   NA                100                50       0.5000
#> 47   NA   NA   NA                100                50       0.5000
#> 48  6.0   12   30                 NA                NA           NA
#> 49  6.0   12   30                 NA                NA           NA
#> 50  6.0   12   30                 NA                NA           NA
#> 51  6.0   12   30                 NA                NA           NA
#> 52  6.0   12   30                 NA                NA           NA
#> 53  6.0   12   30                 NA                NA           NA
#> 54   NA   NA   NA                 NA                NA      10.7485
#> 55   NA   NA   NA                 NA                NA      10.7485
#> 56   NA   NA   NA                 NA                NA      10.7485
#> 57   NA   NA   NA                 NA                NA      10.7485
#> 58   NA   NA   NA                 NA                NA      10.7485
#> 59   NA   NA   NA                 NA                NA      10.7485