From: emilie Date: Fri, 21 Apr 2017 14:56:37 +0000 (+0200) Subject: still some problems with LLF X-Git-Url: https://git.auder.net/%7B%7B%20asset%28%27mixstore/css/img/doc/html/%7B%7B%20targetUrl%20%7D%7D?a=commitdiff_plain;h=f7ac8e154ed78624db1a9992adb5576cae499989;p=valse.git still some problems with LLF --- diff --git a/pkg/R/main.R b/pkg/R/main.R index 0a3487b..632d90b 100644 --- a/pkg/R/main.R +++ b/pkg/R/main.R @@ -127,10 +127,19 @@ valse <- function(X, Y, procedure = "LassoMLE", selecMod = "DDSE", gamma = 1, mi print(tableauRecap) modSel <- capushe::capushe(tableauRecap, n) indModSel <- if (selecMod == "DDSE") - as.numeric(modSel@DDSE@model) else if (selecMod == "Djump") - as.numeric(modSel@Djump@model) else if (selecMod == "BIC") - modSel@BIC_capushe$model else if (selecMod == "AIC") + { + as.numeric(modSel@DDSE@model) + } else if (selecMod == "Djump") + { + as.numeric(modSel@Djump@model) + } else if (selecMod == "BIC") + { + modSel@BIC_capushe$model + } else if (selecMod == "AIC") + { modSel@AIC_capushe$model + } + mod <- as.character(tableauRecap[indModSel, 1]) listMod <- as.integer(unlist(strsplit(mod, "[.]"))) diff --git a/pkg/data/script_data.R b/pkg/data/script_data.R index 6b90712..d425a38 100644 --- a/pkg/data/script_data.R +++ b/pkg/data/script_data.R @@ -11,5 +11,5 @@ Beta[1:4,1:4,2] = -2*diag(4) #Data = generateXY(100, c(0.5,0.5), rep(0,p), Beta, diag(p), covY) -#Res = valse(Data$X,Data$Y, fast=FALSE, plot=FALSE, verbose = TRUE, kmax=2, compute_grid_lambda = FALSE, -# grid_lambda = seq(0.2,2,length = 50), size_coll_mod = 50) +#Res = valse(Data$X,Data$Y, fast=FALSE, plot=FALSE, verbose = TRUE, kmax=2, size_coll_mod = 100, +# selecMod = "BIC")