ROPECA reproducibility-optimization method
ROPECA reproducibility-optimization method
ROPECA optimizes the reproducibility of statistical testing on peptide-level and aggregates the peptide-level changes to determine differential protein-level expression.
summary_ROPECA_median_p.scaled
Other modelling:
Contrasts
,
ContrastsMissing
,
ContrastsModerated
,
ContrastsPlotter
,
ContrastsProDA
,
ContrastsTable
,
INTERNAL_FUNCTIONS_BY_FAMILY
,
LR_test()
,
Model
,
build_model()
,
contrasts_fisher_exact()
,
get_anova_df()
,
get_complete_model_fit()
,
get_p_values_pbeta()
,
isSingular_lm()
,
linfct_all_possible_contrasts()
,
linfct_factors_contrasts()
,
linfct_from_model()
,
linfct_matrix_contrasts()
,
merge_contrasts_results()
,
model_analyse()
,
model_summary()
,
moderated_p_limma()
,
moderated_p_limma_long()
,
my_contest()
,
my_contrast()
,
my_contrast_V1()
,
my_contrast_V2()
,
my_glht()
,
pivot_model_contrasts_2_Wide()
,
plot_lmer_peptide_predictions()
,
sim_build_models_lm()
,
sim_build_models_lmer()
,
sim_make_model_lm()
,
sim_make_model_lmer()
,
strategy_lmer()
,
summary_ROPECA_median_p.scaled()
prolfqua::ContrastsInterface
-> ContrastsROPECA
Contrast
Contrast
contrast_result
contrast result
modelName
model name
subject_Id
columns with protein ID's
p.adjust
method to use for p.value adjustment
Inherited methods
new()
initialize
ContrastsROPECA$new(
Contrast,
modelName = "ROPECA",
p.adjust = prolfqua::adjust_p_values
)
get_contrasts()
get contrasts
to_wide()
convert to wide format
ContrastsROPECA$to_wide(
columns = c("beta.based.significance", "FDR.beta.based.significance")
)
istar <- istar <- prolfqua::sim_lfq_data_peptide_config(Nprot=50)
#> creating sampleName from fileName column
#> Warning: no nr_children column specified in the data, adding column nr_children and setting to 1.
#> completing cases
istar$config <- old2new(istar$config )
istar_data <- istar$data
modelFunction <-
strategy_lm("abundance ~ group_")
pepIntensity <- istar_data
config <- istar$config$clone(deep = TRUE)
config$table$hierarchyDepth <- 2
config$table$hierarchy_keys_depth()
#> [1] "protein_Id" "peptide_Id"
mod <- build_model(
pepIntensity,
modelFunction,
subject_Id = config$table$hierarchy_keys_depth())
#> Joining with `by = join_by(protein_Id, peptide_Id)`
Contr <- c("AvsCtrl" = "group_A - group_Ctrl")
contr <- prolfqua::Contrasts$new(mod, Contr)
dim(contr$get_contrasts())
#> determine linear functions:
#> Warning: Warn 'linfct_matrix_contrasts':In argument: `AvsCtrl = group_A - group_Ctrl`.
#> Warning: Warn 'linfct_matrix_contrasts':In argument: `avg_AvsCtrl = (group_A + group_Ctrl)/2`.
#> Warning: Warn 'linfct_matrix_contrasts':In argument: `AvsCtrl = group_A - group_Ctrl`.
#> Warning: Warn 'linfct_matrix_contrasts':In argument: `avg_AvsCtrl = (group_A + group_Ctrl)/2`.
#> Warning: Warn 'linfct_matrix_contrasts':In argument: `AvsCtrl = group_A - group_Ctrl`.
#> Warning: Warn 'linfct_matrix_contrasts':In argument: `avg_AvsCtrl = (group_A + group_Ctrl)/2`.
#> compute contrasts:
#> computing contrasts.
#> Joining with `by = join_by(protein_Id, peptide_Id, contrast)`
#> [1] 149 14
contrM <- prolfqua::ContrastsModerated$new(contr)
dim(contrM$get_contrasts())
#> [1] 149 14
contrast <- prolfqua::ContrastsROPECA$new(contrM)
contrast$get_contrasts()
#> # A tibble: 48 × 9
#> # Groups: contrast [1]
#> modelName protein_Id contrast n diff statistic avgAbd
#> <chr> <chr> <chr> <int> <dbl> <dbl> <dbl>
#> 1 ROPECA 0EfVhX~7161 AvsCtrl 4 -0.124 -0.260 19.9
#> 2 ROPECA 0m5WN4~3543 AvsCtrl 1 -8.74 -12.7 23.1
#> 3 ROPECA 76k03k~9735 AvsCtrl 3 -8.52 -9.63 22.1
#> 4 ROPECA 7QuTub~5556 AvsCtrl 11 0.925 1.35 23.2
#> 5 ROPECA 7cbcrd~0495 AvsCtrl 2 -1.35 -1.92 17.9
#> 6 ROPECA 7soopj~3451 AvsCtrl 2 2.50 3.64 26.9
#> 7 ROPECA 9VUkAq~8655 AvsCtrl 7 2.71 3.22 25.4
#> 8 ROPECA At886V~0359 AvsCtrl 1 -7.70 -7.10 15.0
#> 9 ROPECA CGzoYe~1248 AvsCtrl 4 -7.45 -7.96 18.0
#> 10 ROPECA CtOJ9t~1391 AvsCtrl 2 -5.48 -8.06 18.4
#> # ℹ 38 more rows
#> # ℹ 2 more variables: beta.based.significance <dbl>,
#> # FDR.beta.based.significance <dbl>
contrast <- prolfqua::ContrastsROPECA$new(contr)
tmp <- contrast$get_contrasts()
dim(tmp)
#> [1] 48 9
pl <- contrast$get_Plotter()
contrast$to_wide()
#> # A tibble: 48 × 4
#> protein_Id diff.AvsCtrl beta.based.significance.Avs…¹ FDR.beta.based.signi…²
#> <chr> <dbl> <dbl> <dbl>
#> 1 0EfVhX~7161 -0.124 1.00e+ 0 1.00e+ 0
#> 2 0m5WN4~3543 -8.74 1.19e- 7 6.34e- 7
#> 3 76k03k~9735 -8.52 1.02e-11 2.46e-10
#> 4 7QuTub~5556 0.925 1.46e- 2 2.19e- 2
#> 5 7cbcrd~0495 -1.35 1.48e- 1 1.97e- 1
#> 6 7soopj~3451 2.50 2.88e- 4 6.01e- 4
#> 7 9VUkAq~8655 2.71 4.34e- 6 1.30e- 5
#> 8 At886V~0359 -7.70 1.55e- 3 2.66e- 3
#> 9 CGzoYe~1248 -7.45 8.97e-10 1.08e- 8
#> 10 CtOJ9t~1391 -5.48 9.75e- 1 1.00e+ 0
#> # ℹ 38 more rows
#> # ℹ abbreviated names: ¹beta.based.significance.AvsCtrl,
#> # ²FDR.beta.based.significance.AvsCtrl
contrast$get_linfct()
#> (Intercept) group_B group_Ctrl
#> AvsCtrl 0 0 -1.0
#> avg_AvsCtrl 1 0 0.5
contrast$get_contrast_sides()
#> # A tibble: 1 × 3
#> contrast group_1 group_2
#> <chr> <chr> <chr>
#> 1 AvsCtrl group_A group_Ctrl
pl$histogram()
#> $beta.based.significance
#>
#> $FDR.beta.based.significance
#>
pl$ma_plot()