Re: [R] break the long R code lines automatically

2010-08-24 Thread heyi xiao
asts) xlist[[i]] <- factor(x[, ncontrasts - i + 1], levels = c(0, 1))             counts <- as.vector(table(xlist))             structure(cbind(outcomes, Counts = counts), class = "VennCounts")       }   --- On Tue, 8/24/10, Yihui Xie wrote

Re: [R] break the long R code lines automatically

2010-08-24 Thread Yihui Xie
Actually I've implemented Charles' idea in the function tidy.source() in package 'animation' years ago. An example can be found here: http://animation.yihui.name/animation:misc#tidy_up_r_source BTW, you might be interested in the 'formatR' package if you are somehow addicted to GUI: http://yihui.n

Re: [R] break the long R code lines automatically

2010-08-24 Thread Charles C. Berry
On Tue, 24 Aug 2010, heyi xiao wrote: Dear all, I have written some R source program with many thousands of lines. I didn???t insert line breaks automatically or manually for the long lines. But now I would like to edit the source code in Emacs/ESS to make it more formal as a package. One o

[R] break the long R code lines automatically

2010-08-24 Thread heyi xiao
Dear all, I have written some R source program with many thousands of lines. I didn’t insert line breaks automatically or manually for the long lines. But now I would like to edit the source code in Emacs/ESS to make it more formal as a package. One of the major problems here is how to break