This function estimates the production risk of an experimental treatment compared to the control treatment using time series data. We suggest applying the ERA.Prepare function to data before using with this function.

RiskCalc(Data, PLevel = "PrName", Out.Codes = 101, MinYear = 3)

Arguments

Data

A prepared (ERA) dataset, see the ERA.Prepare function.

PLevel

The column name of the variable in Data that describes the practice. Use this parameter to choose different levels of the practice hierarchy. Default = PrName (Practice).

Out.Codes

A vector of outcome codes to consider in the analysis. Default = 101 (Crop Yield).

MinYear

An integer value for the minimum length of a MYO sequence. Sequences with fewer growing season than this number are excluded from analysis. Default = 3.

Value

A list of two data.tables Risk and Risk.Averages. Risk contains statistics calculated for each value of UID and has the fields:

  • UID = a unique identifier based on the field Outcome,Practice,Practice.Base,Practice.Code,Code,ID,Site.ID,EU,T.Descrip,C.Descrip,T.NI,T.NO,C.NI,C.NO,Tree,Variety,Diversity, and Rep.

  • N.Years= the number of unique growing seasons reported for each value of UID.

  • N.Obs = the total number of observation for a value of UID.

  • Diff.Mean = mean difference between experimental and control treatments (mean(MeanT-MeanC))

  • Diff.SD = standard deviation of mean difference (sd(MeanT-MeanC))

  • Diff.t.stat = t-statistic of mean difference (.Mean/(.SD/N.Obs^0.5))

  • Diff.p.val = probability of mean difference being <0 (pt(Diff.t.stat,N.Obs-1,lower.tail = T))

  • Mean.C = mean of control treatment

  • Mean.T = mean of experimental treatment

  • Mean.T.SD = standard deviation of experimental treatment

  • Mean.t.stat = t-statistic for MeanT < MeanC (Mean.T-Mean.C)/(Mean.T.SD/N.Obs^0.5)

  • Mean.p.val = probability of MeanT < MeanC (pt(Mean.t.stat,N.Obs-1,lower.tail = T))

  • N.Obs.Study = number of observations a study (Code column) contributes to a combination of practice x outcome

Risk.Averages is the data in the Risk table averaged with weighting across practice x outcome combinations. Additional fields are:

  • Mean.Seq.Len= the mean value of Risk$N.Years

  • Median.Seq.Len= the median value of Risk$N.Years

  • N.Studies = the number of studies contributing MYOs

  • Total.Obs= the total number of observations contributing to MYOs

  • N.Obs= the total number of MYOs

  • Diff.p.val.se = the standard error of Risk$Diff.p.val

  • Mean.p.val.se = the standard error of Risk$Mean.p.val

  • Diff.CI95low = lower 95% confidence interval of Diff.p.val

  • Diff.CI95high = upper 95% confidence interval of Diff.p.val

  • Mean.CI95low = lower 95% confidence interval of Mean.p.val

  • Mean.CI95high = upper 95% confidence interval of Mean.p.val

Details

Method: We adapted a lower confidence limit (LCL) approach (e.g. Hildebrand1996, Yamoah2000, Sirrine2010) to estimate production risk as:

  1. Risk.Means = the probability of the mean experimental treatment yielding lower than the control treatment; and

  2. Risk.Diff = the probability of the mean yield difference between experimental and control treatments being less than 0.

A minimum of three seasons of yield data from the same experimental treatments are required to calculate risk and this is the default threshold for the analyses presented here. The minimum number of season for a multi-year observation (MYO) to be included in analyses can be adjusted using the MinYear parameter.

Statistics are reported aggregated to the level of practice hierarchy specified in the PLevel parameter.

Outcomes are analyzed at the subindicator level. Whilst any outcome(s) can be used with this function, it's primary purpose is to analyze productivity outcomes such as crop yield or net returns.

Weightings are applied to mean and error estimates as per the methods described in the ERA.Analyze function.