Skip to content

Commit

Permalink
3.18-2
Browse files Browse the repository at this point in the history
  • Loading branch information
alexanderrobitzsch committed Jan 10, 2024
1 parent 2954120 commit eba4fbc
Show file tree
Hide file tree
Showing 12 changed files with 91 additions and 71 deletions.
6 changes: 3 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Package: miceadds
Type: Package
Title: Some Additional Multiple Imputation Functions, Especially for 'mice'
Version: 3.17-34
Date: 2023-10-20 20:14:09.576992
Version: 3.18-2
Date: 2024-01-10 09:23:28
Author:
Alexander Robitzsch [aut,cre] (<https://orcid.org/0000-0002-8226-3132>),
Simon Grund [aut] (<https://orcid.org/0000-0002-1290-8986>),
Expand Down Expand Up @@ -47,7 +47,7 @@ Enhances:
simputation
URL:
https://github.com/alexanderrobitzsch/miceadds,
https://sites.google.com/site/alexanderrobitzsch2/software
https://sites.google.com/view/alexander-robitzsch/software
License:
GPL (>= 2)
BugReports:
Expand Down
6 changes: 4 additions & 2 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,8 @@ importFrom(Rcpp, sourceCpp)
#############################
## exports

export(complete.mids.1chain)
export(complete.mids.nmi)
# export(complete.mids.1chain)
# export(complete.mids.nmi)
export(create.designMatrices.waldtest)
export(crlrem)
export(cwc)
Expand Down Expand Up @@ -371,6 +371,8 @@ S3method(coef, mipo.nmi)
S3method(coef, ml_mcmc)
S3method(coef, pool_mi)
S3method(coef, lmer_vcov)
S3method(complete, mids.1chain)
S3method(complete, mids.nmi)
S3method(MIcombine, NestedImputationResultList)
S3method(plot, mids.1chain)
S3method(plot, ml_mcmc)
Expand Down
2 changes: 1 addition & 1 deletion R/RcppExports.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## File Name: RcppExports.R
## File Version: 3.017034
## File Version: 3.018002
# Generated by using Rcpp::compileAttributes() -> do not edit by hand
# Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393

Expand Down
25 changes: 12 additions & 13 deletions R/complete.miceadds.R
Original file line number Diff line number Diff line change
@@ -1,27 +1,26 @@
## File Name: complete.miceadds.R
## File Version: 0.11
## File Version: 0.124


#######################################################
# complete function for nested multiple imputation
complete.mids.nmi <- function( x, action=c(1,1) )
#*** complete function for nested multiple imputation
complete.mids.nmi <- function( data, action=c(1,1), ... )
{
x <- data
if ( x$type=="mice" ){
x1 <- x$imp
data <- mice::complete( x1[[ action[1] ]], action=action[2] )
data <- mice::complete( data=x1[[ action[1] ]], action=action[2], ... )
}
if ( x$type=="mice.1chain" ){
data <- complete.mids.1chain( x$imp[[ action[1] ]], action=action[2] )
data <- complete.mids.1chain( x$imp[[ action[1] ]], action=action[2], ...)
}
return(data)
}
#######################################################


#######################################################
# complete function for objects of class mids.1chain
complete.mids.1chain <- function( x, action=1 )
#*** complete function for objects of class mids.1chain
complete.mids.1chain <- function( data, action=1, ...)
{
mice::complete( x$midsobj, action=action )
x <- data
data <- mice::complete( data=x$midsobj, action=action, ...)
return(data)
}
#######################################################

2 changes: 1 addition & 1 deletion R/datalist2mids.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## File Name: datalist2mids.R
## File Version: 0.41
## File Version: 0.432

datalist2mids <- function( dat.list, progress=FALSE )
{
Expand Down
4 changes: 2 additions & 2 deletions R/mice.1chain.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## File Name: mice.1chain.R
## File Version: 0.672
## File Version: 0.673

#*** apply mice algorithm in a single chain
mice.1chain <- function(data, burnin=10, iter=20, Nimp=10,
Expand Down Expand Up @@ -59,7 +59,7 @@ mice.1chain <- function(data, burnin=10, iter=20, Nimp=10,
implist[[mm+1]] <- imp1 <- mice::mice( data, maxit=maxit_temp, m=1,
method=method, where=where, visitSequence=visitSequence,
blots=blots, post=post, defaultMethod=defaultMethod,
printFlag=printFlag, seed=seed,
printFlag=printFlag, seed=seed,
data.init=mice::complete(implist[[mm]], action=1), ... )
datlist[[mm]] <- dat0 <- mice::complete( imp1, 1 )
chainMean <- rbind( chainMean, t( imp1$chainMean[,,1] ) )
Expand Down
3 changes: 2 additions & 1 deletion R/systime.R
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
## File Name: systime.R
## File Version: 0.11
## File Version: 0.124


#-- several variants for getting system time
systime <- function()
{
s1 <- paste(Sys.time())
s1 <- substring(s1,1,19)
res <- c( s1, substring( s1, 1,10) )
res <- c(res, gsub("-","",res[2] ) )
s1a <- substring( s1, 1, 16 )
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ all necessary information on the used librarys, the R version, and the OS it is

The manual can be found here [https://alexanderrobitzsch.github.io/miceadds/](https://alexanderrobitzsch.github.io/miceadds/)

#### CRAN version `miceadds` 3.16-18 (2023-01-06)
#### CRAN version `miceadds` 3.17-44 (2024-01-08)


[![CRAN_Status_Badge](http://www.r-pkg.org/badges/version-last-release/miceadds)](https://cran.r-project.org/package=miceadds)
Expand All @@ -24,9 +24,9 @@ The CRAN version can be installed from within R using:
utils::install.packages("miceadds")
```

#### GitHub version `miceadds` 3.17-34 (2023-10-20)
#### GitHub version `miceadds` 3.18-2 (2024-01-10)

[![](https://img.shields.io/badge/github%20version-3.17--34-orange.svg)](https://github.com/alexanderrobitzsch/miceadds)&#160;&#160;
[![](https://img.shields.io/badge/github%20version-3.18--2-orange.svg)](https://github.com/alexanderrobitzsch/miceadds)&#160;&#160;

The version hosted [here](https://github.com/alexanderrobitzsch/miceadds) is the development version of `miceadds`.
The GitHub version can be installed from within R using:
Expand Down
2 changes: 1 addition & 1 deletion inst/CITATION
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ citHeader( paste0( "To cite the '", pkg , "' package in publications use:") )
bibentry(key = paste0(pkg, "_", meta$Version),
bibtype = "Manual",
title = paste0( pkg , ": " , pkg_title ) ,
author = personList( person_list1 ),
author = c( person_list1 ),
year = year,
note = vers,
url = paste0( "https://CRAN.R-project.org/package=", pkg) ,
Expand Down
23 changes: 18 additions & 5 deletions inst/NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -44,21 +44,34 @@ CHANGELOG miceadds


--------------------------------------------------------------------------
VERSIONS miceadds 3.17 | 2023-10-20 | Last: miceadds 3.17-34
VERSIONS miceadds 3.18 | 2024-01-10 | Last: miceadds 3.18-2
--------------------------------------------------------------------------

xxx * ---


DATA * ---
EXAMP * ---



--------------------------------------------------------------------------
VERSIONS miceadds 3.17 | 2024-01-08 | Last: miceadds 3.17-44
--------------------------------------------------------------------------

ADDED * added argument 'derived_vars' in mice.impute.pls() for including
derived variables in PLS dimension reduction
(requested by Karoline Sachse)
FIXED * fixed specification issues in mice.1chain()

NOTE * rechanged functionality of systime() due to changes of the
Sys.time() function since R 4.3.1
NOTE * complete functions in miceadds are now declared as a method in
the manual. Moreover, renamed argument 'x' into 'data'
(requested by Kurt Hornik from the CRAN team)

DATA * ---
EXAMP * mice.impute.pls (1), lm.cluster (3)




--------------------------------------------------------------------------
VERSIONS miceadds 3.16 | 2023-01-06 | Last: miceadds 3.16-18
--------------------------------------------------------------------------
Expand Down
13 changes: 9 additions & 4 deletions man/complete.miceadds.Rd
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
%% File Name: complete.miceadds.Rd
%% File Version: 0.20
%% File Version: 0.214

\name{complete.miceadds}
\alias{complete.mids.nmi}
Expand All @@ -17,14 +17,18 @@ Creates imputed dataset from a \code{mids.nmi} or \code{mids.1chain} object.
}

\usage{
complete.mids.nmi( x, action=c(1,1) )
\method{complete}{mids.nmi}(data, action=c(1,1), ...)

complete.mids.1chain( x, action=1 )
\method{complete}{mids.1chain}(data, action=1, ...)
}

% complete.mids.nmi( x, action=c(1,1) )

% complete.mids.1chain( x, action=1 )

%- maybe also 'usage' for other objects documented here.
\arguments{
\item{x}{
\item{data}{
Object of class \code{mids.nmi} (for \code{complete.mids.nmi}) or
\code{mids.1chain} (for \code{complete.mids.1chain})
}
Expand All @@ -33,6 +37,7 @@ A vector of length two indicating to indices of between and within
imputed dataset for for \code{complete.mids.nmi} and an integer for the
index of imputed dataset for \code{complete.mids.1chain}.
}
\item{\dots}{More arguments to be passed}
}

%\details{
Expand Down
Loading

0 comments on commit eba4fbc

Please sign in to comment.