[ESS] List/menu of code chunks for Rnw files

A.J. Rossini blindglobe at gmail.com
Wed Jun 8 02:17:22 CEST 2005

I've not been successful in getting it working "right", i.e. I need to
appropriately add imenu hooks for noweb minor mode that override
mode-specific imenu generation and pop it into a single "result".

There is an alternative noweb mode for XEmacs only, which does half of
what you want (i.e. provides better guidance for hopping around chunks
-- it's actually really slick).

I'll have to dig it up (or perhaps you might find it on the WWW somewhere).

On 6/7/05, Gorjanc Gregor <Gregor.Gorjanc at bfro.uni-lj.si> wrote:
> Hello to everyone!
> R, Sweave and ESS are really great and they increased my performance as
> well as reproducibility. Since Rnw files can become long I find it hard
> to navigate through the file. Usually I am interested in particular
> code chunk and I help myself with search, but you know ... Is there
> any way to get a list o code chunks or beter imenu for chunks? I see R
> functions and data in Imenu already, which is great. I tried to google
> around but with no good result.
> Thanks!
> P.S. I have the following in my .emacs files relates to ESS.
> (require 'ess-site)
> ;; Sweave - statistical reports
> ;;  http://www.ci.tuwien.ac.at/~leisch/Sweave/
> (defun Rnw-mode ()
>   (require 'ess-noweb)
>   (noweb-mode)
>   (if (fboundp 'R-mode)
>       (setq noweb-default-code-mode 'R-mode)))
> (add-to-list 'auto-mode-alist '("\\.Rnw\\'" . Rnw-mode))
> (add-to-list 'auto-mode-alist '("\\.Snw\\'" . Rnw-mode))
> (setq reftex-file-extensions
>       '(("Snw" "Rnw" "nw" "tex" ".tex" ".ltx") ("bib" ".bib")))
> (setq TeX-file-extensions
>       '("Snw" "Rnw" "nw" "tex" "sty" "cls" "ltx" "texi" "texinfo"))
> Lep pozdrav / With regards,
>     Gregor Gorjanc
> ----------------------------------------------------------------------
> University of Ljubljana
> Biotechnical Faculty        URI: http://www.bfro.uni-lj.si/MR/ggorjan
> Zootechnical Department     mail: gregor.gorjanc <at> bfro.uni-lj.si
> Groblje 3                   tel: +386 (0)1 72 17 861
> SI-1230 Domzale             fax: +386 (0)1 72 17 888
> Slovenia, Europe
> ----------------------------------------------------------------------
> "One must learn by doing the thing; for though you think you know it,
>  you have no certainty until you try." Sophocles ~ 450 B.C.
> ______________________________________________
> ESS-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/ess-help


"Commit early,commit often, and commit in a repository from which we can easily
roll-back your mistakes" (AJR, 4Jan05).

A.J. Rossini
blindglobe at gmail.com

More information about the ESS-help mailing list