STOCfree_data | R Documentation |
STOCfree_data class
STOCfree_data( test_data = data.frame(), test_herd_col = NULL, test_date_col = NULL, test_res_col = NULL, test_name_col = NULL, status_dynamics_scale = "logit", risk_factor_data = NULL, risk_herd_col = NULL, risk_date_col = NULL, risk_factor_col = NULL, risk_factor_type = c("continuous", "categorical"), lag1 = 0, lag2 = 0, time_interval = c("month", "year", "week"), FUN = sum )
test_data |
a data.frame containing test results |
test_herd_col |
name of the column with herd / farm identifiers |
test_date_col |
name of the column with date of test |
test_res_col |
name of the column with test results. Test results should be codes as 0 for negative results and 1 for positive results. |
test_name_col |
when several tests are used, name of the column containing the test names |
status_dynamics_scale |
scale on which priors for status dynamics are defined. The default is 'proba' and uses Beta priors. If 'logit' is used as an argument, the prior distributions will be normal distributions on the logit scale. |
risk_factor_data |
a data.frame containing the risk factors |
risk_herd_col |
name of the column with herd / farm identifiers |
risk_date_col |
name of the column with date when the risk factors apply |
risk_factor_col |
name of the column(s) with risk factor values |
risk_factor_type |
risk factor type. Must be either continuous or categorical |
lag1 |
start of the time interval for risk factor aggregation |
lag2 |
end of the time interval for risk factor aggregation |
time_interval |
function used for risk factor aggregation. By default sum() is used, the values are added. |
FUN |
function used when aggregating the data. By default sum() is used, the values are added. |
A list of class STOCfree_data. A specific sub-class is defined based on the input.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.