[ESS] Fwd: Re: Indenting with magrittr and %>%
Kasper Daniel Hansen
k@@perd@n|e|h@n@en @end|ng |rom gm@||@com
Fri Mar 23 09:56:28 CET 2018
I know I am proposing (a little) work, but some screenshots would be nice,
both of what doesn't work, and what supposedly work amazingly.
On Fri, Mar 23, 2018 at 3:10 AM, Marie-Helene Burle <msb2 using sfu.ca> wrote:
> PS: I didn't mention it in my first reply, but aggressive-indent works
> very well with pipes. I use them all the time (big fan of the tidyverse and
> magrittr here too) and the formatting is spot on. I follow Hadley's
> formatting recommendations (including the max 80 characters/line), so all
> my chains of pipes are vertical (new line at each new pipe) and they are
> indented in a very proper fashion automatically. Throw some comas, "+",
> nested functions, etc. and everything will be indented at the proper level,
> or almost (very few cases where things aren't aligning perfectly).
>
> You might want to give it a try :)
>
> Marie
>
> --
> Marie-Helene Burle
> PhD candidate
> Centre for Wildlife Ecology
> Simon Fraser University
> Tel: (+1) 778 782-5618
> Fax: (+1) 778 782-3496
> http://www.sfu.ca/content/sfu/biology/people/profiles/msb2.html
> https://github.com/prosoitos
>
>
>
> Marie-Helene Burle <msb2 using sfu.ca> writes:
>
> > Hi William,
> >
> > I use the package aggressive-indent (https://github.com/Malabarba/
> aggressive-indent-mode) and it works very well in ESS (as in most other
> modes).
> >
> > I hope this helps.
> >
> > Best,
> >
> > Marie
> >
> > --
> > Marie-Helene Burle
> > PhD candidate
> > Centre for Wildlife Ecology
> > Simon Fraser University
> > Tel: (+1) 778 782-5618
> > Fax: (+1) 778 782-3496
> > http://www.sfu.ca/content/sfu/biology/people/profiles/msb2.html
> > https://github.com/prosoitos
> >
> >
> >
> > William Denton <wtd using pobox.com> writes:
> >
> >> I'm a big fan of %>% from magrittr and the tidyverse, but I can't get
> indenting
> >> working with it. I have a long chain of pipes that I'd like to line up
> one by
> >> one on different lines, but they just end up flush left.
> >>
> >> Can anyone point me to their configuration that makes %>% indents work
> nicely?
> >>
> >> This is what I have now (it's a bit jumbled):
> >>
> >> https://github.com/wdenton/.emacs.d/blob/master/setup/setup-ess.el
> >>
> >> Thanks,
> >>
> >> Bill
> >>
> >> --
> >> William Denton :: Toronto, Canada --- Listening to Art:
> https://listeningtoart.org/
> >> https://www.miskatonic.org/ --- GHG.EARTH: http://ghg.earth/
> >> Caveat lector. --- STAPLR: http://staplr.org/
> >>
> >> ______________________________________________
> >> ESS-help using r-project.org mailing list
> >> https://stat.ethz.ch/mailman/listinfo/ess-help
>
> ______________________________________________
> ESS-help using r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/ess-help
>
[[alternative HTML version deleted]]
More information about the ESS-help
mailing list