Skip to content
Snippets Groups Projects
Commit ab0199e6 authored by Arnaud Duvermy's avatar Arnaud Duvermy
Browse files

removing part returning error

parent a7d71b45
No related branches found
No related tags found
No related merge requests found
......@@ -583,57 +583,6 @@ resSimu <- evaluation_report(list_tmb = l_tmb,
resSimu$performances
```
## Evaluate model inference involving mixed effects
For certain experimental scenarios, such as those involving a high number of levels or longitudinal data, the utilization of mixed effects within your design formula can be beneficial. The **HTRfit** simulation framework also offers the capability to assess this type of design formula.
```{r example-evalMixed, warning = FALSE, message = FALSE}
## -- init a design with a high number of levels
input_var_list <- init_variable( name = "varA", mu = 0.2, sd = 0.74, level = 60) %>%
init_variable( name = "varB", mu = 0.27, sd = 0.6, level = 2) %>%
add_interaction( between_var = c("varA", "varB"), mu = 0.44, sd = 0.89)
## -- simulate RNAseq data
mock_data <- mock_rnaseq(input_var_list,
n_genes = 30, ## small number to prevent excessively lengthy vignette construction
min_replicates = 10,
max_replicates = 10,
basal_expression = 5 )
## -- prepare data & fit a model with mixed effect
data2fit = prepareData2fit(countMatrix = mock_data$counts,
metadata = mock_data$metadata,
normalization = F,
response_name = "kij")
l_tmb <- fitModelParallel(formula = kij ~ varB + (varB | varA),
data = data2fit,
group_by = "geneID",
family = glmmTMB::nbinom2(link = "log"),
n.cores = 1)
## -- evaluation
resSimu <- evaluation_report(list_tmb = l_tmb,
dds = NULL,
mock_obj = mock_data,
coeff_threshold = 0.27,
alt_hypothesis = "greater")
```
```{r example-outputResSimuMixed_id, warning = FALSE, message = FALSE, fig.align = 'center', fig.height = 4, fig.width = 5}
## -- identity plot
###### 1) Model params
resSimu$identity$params
###### Dispersion params
resSimu$identity$dispersion
```
```{r example-outputResSimuMixed_metric, warning = FALSE, message = FALSE, fig.align = 'center', fig.height = 4, fig.width = 7}
## -- precision-recall curve
resSimu$precision_recall$params
## -- ROC curve
resSimu$roc$params
## -- Performances metrics
resSimu$performances
```
## Structure of evaluation report object
```{r example-str_eval_report, warning = FALSE, message = FALSE}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment