Running examples in ‘anesrake-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: anesrake
> ### Title: Function to perform full ANES variable selection and weighting.
> ### Aliases: anesrake print.anesrake summary.anesrake
> ### Keywords: ~raking ~variable selection ~weights
> 
> ### ** Examples
> 
> data("anes04")
> 
> anes04$caseid <- 1:length(anes04$age)
> 
> anes04$agecats <- cut(anes04$age, c(0, 25,35,45,55,65,99))
> levels(anes04$agecats) <- c("age1824", "age2534", "age3544",
+           "age4554", "age5564", "age6599")
> 
> marriedtarget <- c(.4, .6)
> 
> agetarg <- c(.10, .15, .17, .23, .22, .13)
> names(agetarg) <- c("age1824", "age2534", "age3544",
+           "age4554", "age5564", "age6599")
> 
> targets <- list(marriedtarget, agetarg)
> 
> names(targets) <- c("married", "agecats")
> 
> outsave <- anesrake(targets, anes04, caseid=anes04$caseid,
+           verbose=TRUE)
[1] "Raking...Iteration 1"
[1] "Current iteration changed total weights by 303.931933308375"
[1] "Raking...Iteration 2"
[1] "Current iteration changed total weights by 50.8760710934304"
[1] "Raking...Iteration 3"
[1] "Current iteration changed total weights by 2.45181318049929"
[1] "Raking...Iteration 4"
[1] "Current iteration changed total weights by 0.115529921587497"
[1] "Raking...Iteration 5"
[1] "Current iteration changed total weights by 0.00543798477855262"
[1] "Raking...Iteration 6"
[1] "Current iteration changed total weights by 0.000255952672060356"
[1] "Raking...Iteration 7"
[1] "Current iteration changed total weights by 1.20470391882233e-05"
[1] "Raking...Iteration 8"
[1] "Current iteration changed total weights by 5.67023318742699e-07"
[1] "Raking...Iteration 9"
[1] "Current iteration changed total weights by 2.66883061206258e-08"
[1] "Raking...Iteration 10"
[1] "Current iteration changed total weights by 1.25607590995003e-09"
[1] "Raking...Iteration 11"
[1] "Current iteration changed total weights by 5.92315085867767e-11"
[1] "Raking...Iteration 12"
[1] "Current iteration changed total weights by 2.76700884427328e-12"
[1] "Raking...Iteration 13"
[1] "Current iteration changed total weights by 2.07389660999979e-13"
[1] "Raking...Iteration 14"
[1] "Current iteration changed total weights by 1.23678844943242e-13"
[1] "Raking...Iteration 15"
[1] "Current iteration changed total weights by 1.2356782264078e-13"
[1] "Raking converged in 15 iterations"
> 
> caseweights <- data.frame(cases=outsave$caseid, weights=outsave$weightvec)
> 
> summary(caseweights)
     cases           weights      
 Min.   :   1.0   Min.   :0.4665  
 1st Qu.: 303.8   1st Qu.:0.6956  
 Median : 606.5   Median :0.8864  
 Mean   : 606.5   Mean   :1.0000  
 3rd Qu.: 909.2   3rd Qu.:1.1874  
 Max.   :1212.0   Max.   :1.7870  
> 
> summary(outsave)
Error in dimnames(x) <- dn : 
  length of 'dimnames' [2] not equal to array extent
Calls: summary -> summary.anesrake -> weightassess -> colnames<-
Execution halted