From 61a0c56863c8cfbf4a5239dba2b53827ee0b12fe Mon Sep 17 00:00:00 2001 From: Robert Rostu Studtrucker Date: Wed, 4 Sep 2024 13:15:10 +0200 Subject: [PATCH] further bug fixing on rmamvmodel --- R/rmaMVModel.R | 6 ------ R/testFunctions.R | 2 +- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/R/rmaMVModel.R b/R/rmaMVModel.R index adc1cec..70a90f3 100644 --- a/R/rmaMVModel.R +++ b/R/rmaMVModel.R @@ -39,16 +39,10 @@ rmaMVModel <- function(yi,vi,measure,d,pred1=NULL,pred2=NULL,nesting=NULL) { if(!is.null(pred1)){ # Parse the JSON string into a list pred1<-jsonlite::fromJSON(pred1) - - # Convert the list to a vector - pred1 <- unlist(pred1) } if(!is.null(pred2)){ # Parse the JSON string into a list pred2<-jsonlite::fromJSON(pred2) - - # Convert the list to a vector - pred2 <- unlist(pred2) } checkParameter(dat,c(yi,vi)) diff --git a/R/testFunctions.R b/R/testFunctions.R index 144a46c..6b6e848 100644 --- a/R/testFunctions.R +++ b/R/testFunctions.R @@ -29,7 +29,7 @@ testpredParameter<-function(pred1){ pred1<-jsonlite::fromJSON(pred1) # Convert the list to a vector - pred1 <- unlist(pred1) + #pred1 <- unlist(pred1, use.names = TRUE) print(pred1) pred1["value"]