I have a sample latex table generation code like this
df<-data.frame(name=rep(letters[1:7],each=24),salary=runif(24*7,100,200))
lst<-tapply(df$salary,df$name,matrix,nrow=4,byrow=T)
xlst<-lapply(lst,xtable)
Now I want to introduce \hdashline automatically after every row in every table and also a \vspace{2em} in between the tables from R code Wat I have tried is this
for(i in seq_along(lst)){
addtorow[i] <- list(pos = list(seq_len(nrow(lst[[i]])-1)),
command = "\\hdashline \n")
}
wat changes do i need to make in for loop..It works when I apply for a single table but not working in a for loop...Any help is much appreciated...