Function extract()
extracts daily or subdaily output and returns it as a tidy data frame.
Arguments
- x
An object returned by simulation functions
spwb
,pwb
orgrowth
.- level
Level of simulation output, either "forest" (stand-level results), "soillayer" (soil layer-level results), "cohort" (cohort-level results), "sunlitleaf" or "shadeleaf" (leaf-level results)
- output
Section of the model output to be explored. See details.
- vars
Variables to be extracted (by default, all of them).
- dates
A date vector indicating the subset of simulated days for which output is desired.
- subdaily
A flag to indicate that subdaily values are desired (see details).
Value
Function extract()
returns a data frame:
If
level = "forest"
, columns are "date" and variable names.If
level = "soillayer"
, columns are "date", "soillayer" and variable names.If
level = "cohort"
,level = "sunlitleaf"
orlevel = "shadeleaf"
, columns are "date", "cohorts", "species" and variable names.If
subdaily = TRUE
, columns are "datetime", "cohorts", "species" and variable names.
Details
When subdaily = FALSE
, parameter output
is used to restrict the section in x
where variables are located. For
example output = "Plants"
will correspond to variables "LAI", "LAIlive", "Transpiration", "StemPLC",... as returned by a call
names(x$Plants)
.
Option subdaily = TRUE
only works when simulations have been carried using control option 'subdailyResults = TRUE' (see defaultControl
).
When using subdaily = TRUE
, parameter output
is not taken into account, and options for parameter vars
are the following:
Variables for
level = "forest"
orlevel = "soillayer"
: Not allowed. An error is raised.Variables for
level = "cohort"
: "E","Ag","An","dEdP","RootPsi","StemPsi","LeafPsi","StemPLC","StemRWC","LeafRWC","StemSympRWC","LeafSympRWC","PWB".Variables for
level = "shadeleaf"
andlevel="sunlitleaf"
: "Abs_SWR","Abs_PAR","Net_LWR","E","Ag","An","Ci","Gsw","VPD","Temp","Psi","iWUE".
Examples
#Load example daily meteorological data
data(examplemeteo)
#Load example plot plant data
data(exampleforest)
#Default species parameterization
data(SpParamsMED)
#Define soil with default soil params (4 layers)
examplesoil <- defaultSoilParams(4)
#Initialize control parameters
control <- defaultControl("Granier")
#Initialize input
x <- spwbInput(exampleforest,examplesoil, SpParamsMED, control)
#Call simulation function (ten days)
S1<-spwb(x, examplemeteo[1:10, ], latitude = 41.82592, elevation = 100)
#> Initial plant water content (mm): 7.05859
#> Initial soil water content (mm): 290.875
#> Initial snowpack content (mm): 0
#> Performing daily simulations
#>
#> [Year 2001]:
#>
#> Final plant water content (mm): 7.05854
#> Final soil water content (mm): 294.814
#> Final snowpack content (mm): 0
#> Change in plant water content (mm): -5.7277e-05
#> Plant water balance result (mm): -5.7277e-05
#> Change in soil water content (mm): 3.93862
#> Soil water balance result (mm): 3.93862
#> Change in snowpack water content (mm): 0
#> Snowpack water balance result (mm): 0
#> Water balance components:
#> Precipitation (mm) 39 Rain (mm) 34 Snow (mm) 5
#> Interception (mm) 9 Net rainfall (mm) 25
#> Infiltration (mm) 30 Infiltration excess (mm) 0 Saturation excess (mm) 0 Capillarity rise (mm) 0
#> Soil evaporation (mm) 3 Herbaceous transpiration (mm) 0 Woody plant transpiration (mm) 2
#> Plant extraction from soil (mm) 2 Plant water balance (mm) -0 Hydraulic redistribution (mm) 0
#> Runoff (mm) 0 Deep drainage (mm) 22
#Extracts daily forest-level output as a data frame
extract(S1, level = "forest")
#> date PET Precipitation Rain Snow NetRain Snowmelt
#> 1 2001-01-01 0.8828475 4.869109 4.869109 0.0000 3.4241795 0.0000
#> 2 2001-01-02 1.6375337 2.498292 2.498292 0.0000 1.0717469 0.0000
#> 3 2001-01-03 1.3017026 0.000000 0.000000 0.0000 0.0000000 0.0000
#> 4 2001-01-04 0.5690790 5.796973 5.796973 0.0000 4.3625616 0.0000
#> 5 2001-01-05 1.6760567 1.884401 1.884401 0.0000 0.7539027 0.0000
#> 6 2001-01-06 1.2077028 13.359801 13.359801 0.0000 11.7240275 0.0000
#> 7 2001-01-07 0.6368075 5.377400 0.000000 5.3774 0.0000000 0.0000
#> 8 2001-01-08 0.8318207 0.000000 0.000000 0.0000 0.0000000 0.0000
#> 9 2001-01-09 1.9823797 0.000000 0.000000 0.0000 0.0000000 0.0000
#> 10 2001-01-10 0.8286873 5.117768 5.117768 0.0000 3.6727363 5.3774
#> Infiltration InfiltrationExcess SaturationExcess Runoff DeepDrainage
#> 1 3.4241795 0 0 0 2.8139811
#> 2 1.0717469 0 0 0 0.2707009
#> 3 0.0000000 0 0 0 0.0000000
#> 4 4.3625616 0 0 0 3.3540764
#> 5 0.7539027 0 0 0 0.1270649
#> 6 11.7240275 0 0 0 4.1214138
#> 7 0.0000000 0 0 0 4.1214138
#> 8 0.0000000 0 0 0 2.6988760
#> 9 0.0000000 0 0 0 0.0000000
#> 10 9.0501360 0 0 0 4.1214138
#> CapillarityRise Evapotranspiration Interception SoilEvaporation
#> 1 0 2.0551277 1.444929 0.4478948
#> 2 0 2.2275907 1.426545 0.5000000
#> 3 0 0.7393064 0.000000 0.5000000
#> 4 0 1.7035902 1.434411 0.1645908
#> 5 0 1.9386268 1.130499 0.5000000
#> 6 0 2.2083424 1.635773 0.3505613
#> 7 0 0.1170754 0.000000 0.0000000
#> 8 0 0.1529199 0.000000 0.0000000
#> 9 0 0.3644111 0.000000 0.0000000
#> 10 0 1.8291943 1.445031 0.2318466
#> HerbTranspiration PlantExtraction Transpiration HydraulicRedistribution
#> 1 0.011023432 0.15128020 0.15128020 0.000000000
#> 2 0.020446613 0.28059934 0.28059934 0.000000000
#> 3 0.016253351 0.22305305 0.22305305 0.000000000
#> 4 0.007105413 0.09748263 0.09748263 0.000000000
#> 5 0.020927620 0.28720044 0.28720044 0.000000000
#> 6 0.015079520 0.20692838 0.20692838 0.000000000
#> 7 0.007951321 0.10912403 0.10912403 0.001234311
#> 8 0.010386260 0.14253364 0.14253364 0.001450852
#> 9 0.024752217 0.33965892 0.33965892 0.000000000
#> 10 0.010346965 0.14196935 0.14196935 0.000000000
#> LAI LAIherb LAIlive LAIexpanded LAIdead Cm LgroundPAR
#> 1 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 2 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 3 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 4 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 5 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 6 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 7 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 8 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 9 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> 10 1.758585 0.1736369 1.584948 1.584948 0 1.390485 40.00754
#> LgroundSWR SWE
#> 1 50.73297 0.0000
#> 2 50.73297 0.0000
#> 3 50.73297 0.0000
#> 4 50.73297 0.0000
#> 5 50.73297 0.0000
#> 6 50.73297 0.0000
#> 7 50.73297 5.3774
#> 8 50.73297 5.3774
#> 9 50.73297 5.3774
#> 10 50.73297 0.0000
#Extracts daily soil layer-level output as a data frame
extract(S1, level = "soillayer")
#> date soillayer SWC RWC REW ML Psi
#> 1 2001-01-01 1 0.3029947 1.0000000 1.0000000 68.17381 -0.03300000
#> 2 2001-01-02 1 0.3029947 1.0000000 1.0000000 68.17381 -0.03300000
#> 3 2001-01-03 1 0.2999851 0.9900671 0.9851034 67.49665 -0.03458985
#> 4 2001-01-04 1 0.3029947 1.0000000 1.0000000 68.17381 -0.03300000
#> 5 2001-01-05 1 0.3021890 0.9973408 0.9960119 67.99252 -0.03341837
#> 6 2001-01-06 1 0.3029947 1.0000000 1.0000000 68.17381 -0.03300000
#> 7 2001-01-07 1 0.3026334 0.9988076 0.9982117 68.09252 -0.03318696
#> 8 2001-01-08 1 0.3021566 0.9972338 0.9958515 67.98523 -0.03343531
#> 9 2001-01-09 1 0.3011137 0.9937920 0.9906896 67.75059 -0.03398491
#> 10 2001-01-10 1 0.3029947 1.0000000 1.0000000 68.17381 -0.03300000
#> 11 2001-01-01 2 0.3029947 1.0000000 1.0000000 116.65297 -0.03300000
#> 12 2001-01-02 2 0.3029947 1.0000000 1.0000000 116.65297 -0.03300000
#> 13 2001-01-03 2 0.3028520 0.9995291 0.9992937 116.59804 -0.03307371
#> 14 2001-01-04 2 0.3029947 1.0000000 1.0000000 116.65297 -0.03300000
#> 15 2001-01-05 2 0.3029947 1.0000000 1.0000000 116.65297 -0.03300000
#> 16 2001-01-06 2 0.3029947 1.0000000 1.0000000 116.65297 -0.03300000
#> 17 2001-01-07 2 0.3029362 0.9998068 0.9997102 116.63043 -0.03303023
#> 18 2001-01-08 2 0.3028572 0.9995461 0.9993193 116.60002 -0.03307104
#> 19 2001-01-09 2 0.3026211 0.9987667 0.9981504 116.50911 -0.03319338
#> 20 2001-01-10 2 0.3029947 1.0000000 1.0000000 116.65297 -0.03300000
#> 21 2001-01-01 3 0.3029947 1.0000000 1.0000000 75.74868 -0.03300000
#> 22 2001-01-02 3 0.3029947 1.0000000 1.0000000 75.74868 -0.03300000
#> 23 2001-01-03 3 0.3029718 0.9999242 0.9998863 75.74294 -0.03301186
#> 24 2001-01-04 3 0.3029947 1.0000000 1.0000000 75.74868 -0.03300000
#> 25 2001-01-05 3 0.3029947 1.0000000 1.0000000 75.74868 -0.03300000
#> 26 2001-01-06 3 0.3029947 1.0000000 1.0000000 75.74868 -0.03300000
#> 27 2001-01-07 3 0.3029947 1.0000000 1.0000000 75.74868 -0.03300000
#> 28 2001-01-08 3 0.3029947 1.0000000 1.0000000 75.74868 -0.03300000
#> 29 2001-01-09 3 0.3029038 0.9996999 0.9995499 75.72595 -0.03304696
#> 30 2001-01-10 3 0.3029947 1.0000000 1.0000000 75.74868 -0.03300000
#> 31 2001-01-01 4 0.3029947 1.0000000 1.0000000 30.29947 -0.03300000
#> 32 2001-01-02 4 0.3029947 1.0000000 1.0000000 30.29947 -0.03300000
#> 33 2001-01-03 4 0.3029801 0.9999516 0.9999275 30.29801 -0.03300756
#> 34 2001-01-04 4 0.3029947 1.0000000 1.0000000 30.29947 -0.03300000
#> 35 2001-01-05 4 0.3029947 1.0000000 1.0000000 30.29947 -0.03300000
#> 36 2001-01-06 4 0.3714823 1.2260354 1.3389904 37.14823 -0.01014118
#> 37 2001-01-07 4 0.3301357 1.0895758 1.1343389 33.01357 -0.02146157
#> 38 2001-01-08 4 0.3029947 1.0000000 1.0000000 30.29947 -0.03300000
#> 39 2001-01-09 4 0.3028336 0.9994681 0.9992023 30.28336 -0.03308327
#> 40 2001-01-10 4 0.3423809 1.1299896 1.1949484 34.23809 -0.01751074
#> 41 2001-01-01 Overall 0.3029947 1.0000000 1.0000000 290.87494 -0.03300000
#> 42 2001-01-02 Overall 0.3029947 1.0000000 1.0000000 290.87494 -0.03300000
#> 43 2001-01-03 Overall 0.3022246 0.9974583 0.9961882 290.13563 -0.03340606
#> 44 2001-01-04 Overall 0.3029947 1.0000000 1.0000000 290.87494 -0.03300000
#> 45 2001-01-05 Overall 0.3028059 0.9993767 0.9990653 290.69365 -0.03309806
#> 46 2001-01-06 Overall 0.3101288 1.0235454 1.0353115 297.72369 -0.03061887
#> 47 2001-01-07 Overall 0.3057138 1.0089738 1.0134583 293.48520 -0.03185402
#> 48 2001-01-08 Overall 0.3027431 0.9991696 0.9987547 290.63341 -0.03313052
#> 49 2001-01-09 Overall 0.3023635 0.9979168 0.9968758 290.26900 -0.03332929
#> 50 2001-01-10 Overall 0.3070975 1.0135406 1.0203071 294.81356 -0.03138654
#> PlantExt HydraulicInput
#> 1 0.1101121597 0.000000000
#> 2 0.2042395378 0.000000000
#> 3 0.1623533844 0.000000000
#> 4 0.0598317765 0.000000000
#> 5 0.2090442749 0.000000000
#> 6 0.1291220756 0.000000000
#> 7 0.0740481550 0.000000000
#> 8 0.0978235152 0.000000000
#> 9 0.2120899092 0.000000000
#> 10 0.0880785653 0.000000000
#> 11 0.0364746151 0.000000000
#> 12 0.0676542767 0.000000000
#> 13 0.0537795028 0.000000000
#> 14 0.0275721699 0.000000000
#> 15 0.0692458442 0.000000000
#> 16 0.0574950510 0.000000000
#> 17 0.0219764367 0.000000000
#> 18 0.0296700778 0.000000000
#> 19 0.0891559413 0.000000000
#> 20 0.0380082159 0.000000000
#> 21 0.0037576026 0.000000000
#> 22 0.0069697208 0.000000000
#> 23 0.0055403463 0.000000000
#> 24 0.0059798769 0.000000000
#> 25 0.0071336836 0.000000000
#> 26 0.0121133591 0.000000000
#> 27 -0.0009970584 0.001234311
#> 28 -0.0009952259 0.001450852
#> 29 0.0224260395 0.000000000
#> 30 0.0097075082 0.000000000
#> 31 0.0009358264 0.000000000
#> 32 0.0017358006 0.000000000
#> 33 0.0013798165 0.000000000
#> 34 0.0040988117 0.000000000
#> 35 0.0017766353 0.000000000
#> 36 0.0081978912 0.000000000
#> 37 0.0140964996 0.000000000
#> 38 0.0160352766 0.000000000
#> 39 0.0159870288 0.000000000
#> 40 0.0061750624 0.000000000
#> 41 0.1512802038 0.000000000
#> 42 0.2805993358 0.000000000
#> 43 0.2230530501 0.000000000
#> 44 0.0974826350 0.000000000
#> 45 0.2872004380 0.000000000
#> 46 0.2069283770 0.000000000
#> 47 0.1091240328 0.001234311
#> 48 0.1425336437 0.001450852
#> 49 0.3396589188 0.000000000
#> 50 0.1419693517 0.000000000
#Extracts daily cohort-level output as a data frame
extract(S1, level = "cohort")
#> date cohort species LAI LAIlive FPAR
#> 1 2001-01-01 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 2 2001-01-02 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 3 2001-01-03 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 4 2001-01-04 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 5 2001-01-05 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 6 2001-01-06 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 7 2001-01-07 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 8 2001-01-08 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 9 2001-01-09 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 10 2001-01-10 T1_148 Pinus halepensis 0.84874773 0.84874773 92.18285
#> 11 2001-01-01 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 12 2001-01-02 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 13 2001-01-03 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 14 2001-01-04 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 15 2001-01-05 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 16 2001-01-06 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 17 2001-01-07 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 18 2001-01-08 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 19 2001-01-09 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 20 2001-01-10 T2_168 Quercus ilex 0.70557382 0.70557382 72.36365
#> 21 2001-01-01 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 22 2001-01-02 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 23 2001-01-03 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 24 2001-01-04 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 25 2001-01-05 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 26 2001-01-06 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 27 2001-01-07 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 28 2001-01-08 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 29 2001-01-09 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> 30 2001-01-10 S1_165 Quercus coccifera 0.03062604 0.03062604 44.32407
#> AbsorbedSWRFraction Transpiration GrossPhotosynthesis PlantPsi
#> 1 35.076344 0.092472560 0.89344066 -0.03300000
#> 2 35.076344 0.171521046 1.55980140 -0.03300000
#> 3 35.076344 0.136344915 1.30760344 -0.03300000
#> 4 35.076344 0.059585792 0.59655088 -0.03437896
#> 5 35.076344 0.175556080 1.61688314 -0.03300000
#> 6 35.076344 0.126487190 1.30939128 -0.03336015
#> 7 35.076344 0.066703041 0.74575105 -0.03290834
#> 8 35.076344 0.087125281 0.89105532 -0.03311252
#> 9 35.076344 0.207620713 1.58392702 -0.03338318
#> 10 35.076344 0.086779849 0.85316468 -0.03387227
#> 11 30.444383 0.052754988 0.62572744 -0.03300000
#> 12 30.444383 0.097851630 1.14521586 -0.03300000
#> 13 30.444383 0.077783878 0.92105819 -0.03300000
#> 14 30.444383 0.033995859 0.40652372 -0.03383056
#> 15 30.444383 0.100153590 1.17538187 -0.03300000
#> 16 30.444383 0.072161664 0.86972119 -0.03320960
#> 17 30.444383 0.038055034 0.46739295 -0.03282505
#> 18 30.444383 0.049705553 0.59735290 -0.03301756
#> 19 30.444383 0.118447863 1.33708218 -0.03325008
#> 20 30.444383 0.049508664 0.58955200 -0.03358317
#> 21 2.366131 0.006052657 0.05005525 -0.03300000
#> 22 2.366131 0.011226660 0.08984642 -0.03300000
#> 23 2.366131 0.008924258 0.07350414 -0.03300000
#> 24 2.366131 0.003900984 0.03290302 -0.03410397
#> 25 2.366131 0.011490767 0.09258764 -0.03300000
#> 26 2.366131 0.008279523 0.07115922 -0.03328466
#> 27 2.366131 0.004365958 0.03922423 -0.03278961
#> 28 2.366131 0.005702810 0.04867900 -0.03302076
#> 29 2.366131 0.013590343 0.09935134 -0.03331559
#> 30 2.366131 0.005680839 0.04743368 -0.03372586
#> LeafPLC StemPLC PlantWaterBalance LeafRWC StemRWC LFMC
#> 1 3.713826e-03 1.320577e-11 0.000000e+00 0.9979679 0.9998350 125.89003
#> 2 3.713826e-03 1.320577e-11 0.000000e+00 0.9979679 0.9998350 125.89003
#> 3 3.713826e-03 1.320577e-11 0.000000e+00 0.9979679 0.9998350 125.89003
#> 4 3.941519e-03 1.622580e-11 -7.556383e-05 0.9978830 0.9998281 125.88416
#> 5 3.941519e-03 1.622580e-11 7.556383e-05 0.9979679 0.9998350 125.89003
#> 6 3.941519e-03 1.622580e-11 -1.973564e-05 0.9979457 0.9998332 125.88850
#> 7 3.941519e-03 1.622580e-11 2.475861e-05 0.9979735 0.9998354 125.89042
#> 8 3.941519e-03 1.622580e-11 -1.118882e-05 0.9979610 0.9998344 125.88955
#> 9 3.941519e-03 1.622580e-11 -1.483184e-05 0.9979443 0.9998331 125.88840
#> 10 3.941519e-03 1.622580e-11 -2.680080e-05 0.9979142 0.9998306 125.88632
#> 11 3.473351e-05 1.691266e-06 0.000000e+00 0.9986794 0.9997489 93.07448
#> 12 3.473351e-05 1.691266e-06 0.000000e+00 0.9986794 0.9997489 93.07448
#> 13 3.473351e-05 1.691266e-06 0.000000e+00 0.9986794 0.9997489 93.07448
#> 14 3.673597e-05 1.810103e-06 -1.117624e-05 0.9986462 0.9997425 93.07250
#> 15 3.673597e-05 1.810103e-06 1.117624e-05 0.9986794 0.9997489 93.07448
#> 16 3.673597e-05 1.810103e-06 -2.820075e-06 0.9986710 0.9997473 93.07398
#> 17 3.673597e-05 1.810103e-06 5.173816e-06 0.9986864 0.9997503 93.07490
#> 18 3.673597e-05 1.810103e-06 -2.589997e-06 0.9986787 0.9997488 93.07444
#> 19 3.673597e-05 1.810103e-06 -3.128590e-06 0.9986694 0.9997470 93.07389
#> 20 3.673597e-05 1.810103e-06 -4.482014e-06 0.9986561 0.9997444 93.07309
#> 21 3.473351e-05 4.394058e-08 0.000000e+00 0.9987207 0.9983684 96.39176
#> 22 3.473351e-05 4.394058e-08 0.000000e+00 0.9987207 0.9983684 96.39176
#> 23 3.473351e-05 4.394058e-08 0.000000e+00 0.9987207 0.9983684 96.39176
#> 24 3.740883e-05 4.865223e-08 -2.481630e-06 0.9986779 0.9983139 96.38699
#> 25 3.740883e-05 4.865223e-08 2.481630e-06 0.9987207 0.9983684 96.39176
#> 26 3.740883e-05 4.865223e-08 -6.398948e-07 0.9987096 0.9983543 96.39053
#> 27 3.740883e-05 4.865223e-08 1.112844e-06 0.9987288 0.9983788 96.39267
#> 28 3.740883e-05 4.865223e-08 -5.196272e-07 0.9987199 0.9983674 96.39167
#> 29 3.740883e-05 4.865223e-08 -6.627544e-07 0.9987084 0.9983528 96.39040
#> 30 3.740883e-05 4.865223e-08 -9.222438e-07 0.9986925 0.9983325 96.38863
#> PlantStress
#> 1 0.005808769
#> 2 0.005808769
#> 3 0.005808769
#> 4 0.006168100
#> 5 0.005808769
#> 6 0.005901961
#> 7 0.005785126
#> 8 0.005837834
#> 9 0.005907936
#> 10 0.006035277
#> 11 0.010612890
#> 12 0.010612890
#> 13 0.010612890
#> 14 0.010896118
#> 15 0.010612890
#> 16 0.010684328
#> 17 0.010553279
#> 18 0.010618874
#> 19 0.010698130
#> 20 0.010811714
#> 21 0.003088161
#> 22 0.003088161
#> 23 0.003088161
#> 24 0.003222915
#> 25 0.003088161
#> 26 0.003122782
#> 27 0.003062630
#> 28 0.003090684
#> 29 0.003126549
#> 30 0.003176614
#Select the output tables/variables to be extracted
extract(S1, level ="cohort", output="Plants", vars = c("PlantStress", "StemPLC"))
#> date cohort species PlantStress StemPLC
#> 1 2001-01-01 T1_148 Pinus halepensis 0.005808769 1.320577e-11
#> 2 2001-01-02 T1_148 Pinus halepensis 0.005808769 1.320577e-11
#> 3 2001-01-03 T1_148 Pinus halepensis 0.005808769 1.320577e-11
#> 4 2001-01-04 T1_148 Pinus halepensis 0.006168100 1.622580e-11
#> 5 2001-01-05 T1_148 Pinus halepensis 0.005808769 1.622580e-11
#> 6 2001-01-06 T1_148 Pinus halepensis 0.005901961 1.622580e-11
#> 7 2001-01-07 T1_148 Pinus halepensis 0.005785126 1.622580e-11
#> 8 2001-01-08 T1_148 Pinus halepensis 0.005837834 1.622580e-11
#> 9 2001-01-09 T1_148 Pinus halepensis 0.005907936 1.622580e-11
#> 10 2001-01-10 T1_148 Pinus halepensis 0.006035277 1.622580e-11
#> 11 2001-01-01 T2_168 Quercus ilex 0.010612890 1.691266e-06
#> 12 2001-01-02 T2_168 Quercus ilex 0.010612890 1.691266e-06
#> 13 2001-01-03 T2_168 Quercus ilex 0.010612890 1.691266e-06
#> 14 2001-01-04 T2_168 Quercus ilex 0.010896118 1.810103e-06
#> 15 2001-01-05 T2_168 Quercus ilex 0.010612890 1.810103e-06
#> 16 2001-01-06 T2_168 Quercus ilex 0.010684328 1.810103e-06
#> 17 2001-01-07 T2_168 Quercus ilex 0.010553279 1.810103e-06
#> 18 2001-01-08 T2_168 Quercus ilex 0.010618874 1.810103e-06
#> 19 2001-01-09 T2_168 Quercus ilex 0.010698130 1.810103e-06
#> 20 2001-01-10 T2_168 Quercus ilex 0.010811714 1.810103e-06
#> 21 2001-01-01 S1_165 Quercus coccifera 0.003088161 4.394058e-08
#> 22 2001-01-02 S1_165 Quercus coccifera 0.003088161 4.394058e-08
#> 23 2001-01-03 S1_165 Quercus coccifera 0.003088161 4.394058e-08
#> 24 2001-01-04 S1_165 Quercus coccifera 0.003222915 4.865223e-08
#> 25 2001-01-05 S1_165 Quercus coccifera 0.003088161 4.865223e-08
#> 26 2001-01-06 S1_165 Quercus coccifera 0.003122782 4.865223e-08
#> 27 2001-01-07 S1_165 Quercus coccifera 0.003062630 4.865223e-08
#> 28 2001-01-08 S1_165 Quercus coccifera 0.003090684 4.865223e-08
#> 29 2001-01-09 S1_165 Quercus coccifera 0.003126549 4.865223e-08
#> 30 2001-01-10 S1_165 Quercus coccifera 0.003176614 4.865223e-08