Re: [R] Double / single backticks for inline R code in an Rmarkdown file

2019-10-14 Thread Ashim Kapoor
Dear Yihui,

Thank you and Best Regards,
Ashim

On Mon, Oct 14, 2019 at 7:30 PM Yihui Xie  wrote:

> params$data is "hawaii" in this case, so the output of
>
>   ``r params$data``
>
> is
>
>   `hawaii`
>
> The double backticks don't have any special meaning here. Only the
> inside pair of backticks (i.e. `r `) makes sense to R Markdown (or
> precisely speaking, knitr). The outside pair will be left untouched
> after knitr evaluates the inline R expression `r params$data`. After
> evaluation, there won't be double backticks. This has nothing to do
> with the left curly double quote LaTeX. The result `hawaii` will be
> converted to hawaii if the output format is HTML (or
> \texttt{hawaii} if the output format is LaTeX), but the extra
> backticks in the original Rmd document is completely optional. It all
> depends on whether you want to place the result in a code tag or
> command.
>
> Regards,
> Yihui
> --
> https://yihui.name
>
> On Mon, Oct 14, 2019 at 8:42 AM Jeff Newmiller 
> wrote:
> >
> > No, you don't misunderstand. But you might want to be aware that
> targeting PDF output uses LaTeX which regards double backticks as a method
> of encoding a left curly double quote mark, so this error could derive from
> an incomplete adaptation of the Rmd file for HTML output even though such a
> symbol doesn't make sense there in PDF either.
> >
> > On October 14, 2019 4:35:26 AM PDT, Ashim Kapoor 
> wrote:
> > >Dear All,
> > >
> > >I am reading this file :-
> > >
> > >https://rmarkdown.rstudio.com/lesson-6.html
> > >
> > >My query is : In line 14 of the above file, ie.
> > >
> > >The [marmap](https://cran.r-project.org/web/packages/marmap/index.html)
> > >package provides tools and data for visualizing the ocean floor. Here
> > >is an
> > >example contour plot of marmap's ``r params$data`` dataset.
> > >
> > >Should not the phrase rparams$data be within SINGLE backticks ?
> > >
> > >Do I misunderstand?
> > >
> > >Thank you,
> > >Ashim
> > >
> > >   [[alternative HTML version deleted]]
> > >
> > >__
> > >R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> > >https://stat.ethz.ch/mailman/listinfo/r-help
> > >PLEASE do read the posting guide
> > >http://www.R-project.org/posting-guide.html
> > >and provide commented, minimal, self-contained, reproducible code.
> >
> > --
> > Sent from my phone. Please excuse my brevity.
> >
> > __
> > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> > and provide commented, minimal, self-contained, reproducible code.
>

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Double / single backticks for inline R code in an Rmarkdown file

2019-10-14 Thread Yihui Xie
params$data is "hawaii" in this case, so the output of

  ``r params$data``

is

  `hawaii`

The double backticks don't have any special meaning here. Only the
inside pair of backticks (i.e. `r `) makes sense to R Markdown (or
precisely speaking, knitr). The outside pair will be left untouched
after knitr evaluates the inline R expression `r params$data`. After
evaluation, there won't be double backticks. This has nothing to do
with the left curly double quote LaTeX. The result `hawaii` will be
converted to hawaii if the output format is HTML (or
\texttt{hawaii} if the output format is LaTeX), but the extra
backticks in the original Rmd document is completely optional. It all
depends on whether you want to place the result in a code tag or
command.

Regards,
Yihui
--
https://yihui.name

On Mon, Oct 14, 2019 at 8:42 AM Jeff Newmiller  wrote:
>
> No, you don't misunderstand. But you might want to be aware that targeting 
> PDF output uses LaTeX which regards double backticks as a method of encoding 
> a left curly double quote mark, so this error could derive from an incomplete 
> adaptation of the Rmd file for HTML output even though such a symbol doesn't 
> make sense there in PDF either.
>
> On October 14, 2019 4:35:26 AM PDT, Ashim Kapoor  
> wrote:
> >Dear All,
> >
> >I am reading this file :-
> >
> >https://rmarkdown.rstudio.com/lesson-6.html
> >
> >My query is : In line 14 of the above file, ie.
> >
> >The [marmap](https://cran.r-project.org/web/packages/marmap/index.html)
> >package provides tools and data for visualizing the ocean floor. Here
> >is an
> >example contour plot of marmap's ``r params$data`` dataset.
> >
> >Should not the phrase rparams$data be within SINGLE backticks ?
> >
> >Do I misunderstand?
> >
> >Thank you,
> >Ashim
> >
> >   [[alternative HTML version deleted]]
> >
> >__
> >R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> >https://stat.ethz.ch/mailman/listinfo/r-help
> >PLEASE do read the posting guide
> >http://www.R-project.org/posting-guide.html
> >and provide commented, minimal, self-contained, reproducible code.
>
> --
> Sent from my phone. Please excuse my brevity.
>
> __
> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Double / single backticks for inline R code in an Rmarkdown file

2019-10-14 Thread Ashim Kapoor
Dear Jeff,

Many thanks for your reply.

Best,
Ashim

On Mon, Oct 14, 2019 at 7:07 PM Jeff Newmiller 
wrote:

> No, you don't misunderstand. But you might want to be aware that targeting
> PDF output uses LaTeX which regards double backticks as a method of
> encoding a left curly double quote mark, so this error could derive from an
> incomplete adaptation of the Rmd file for HTML output even though such a
> symbol doesn't make sense there in PDF either.
>
> On October 14, 2019 4:35:26 AM PDT, Ashim Kapoor 
> wrote:
> >Dear All,
> >
> >I am reading this file :-
> >
> >https://rmarkdown.rstudio.com/lesson-6.html
> >
> >My query is : In line 14 of the above file, ie.
> >
> >The [marmap](https://cran.r-project.org/web/packages/marmap/index.html)
> >package provides tools and data for visualizing the ocean floor. Here
> >is an
> >example contour plot of marmap's ``r params$data`` dataset.
> >
> >Should not the phrase rparams$data be within SINGLE backticks ?
> >
> >Do I misunderstand?
> >
> >Thank you,
> >Ashim
> >
> >   [[alternative HTML version deleted]]
> >
> >__
> >R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> >https://stat.ethz.ch/mailman/listinfo/r-help
> >PLEASE do read the posting guide
> >http://www.R-project.org/posting-guide.html
> >and provide commented, minimal, self-contained, reproducible code.
>
> --
> Sent from my phone. Please excuse my brevity.
>

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Double / single backticks for inline R code in an Rmarkdown file

2019-10-14 Thread Jeff Newmiller
No, you don't misunderstand. But you might want to be aware that targeting PDF 
output uses LaTeX which regards double backticks as a method of encoding a left 
curly double quote mark, so this error could derive from an incomplete 
adaptation of the Rmd file for HTML output even though such a symbol doesn't 
make sense there in PDF either.

On October 14, 2019 4:35:26 AM PDT, Ashim Kapoor  wrote:
>Dear All,
>
>I am reading this file :-
>
>https://rmarkdown.rstudio.com/lesson-6.html
>
>My query is : In line 14 of the above file, ie.
>
>The [marmap](https://cran.r-project.org/web/packages/marmap/index.html)
>package provides tools and data for visualizing the ocean floor. Here
>is an
>example contour plot of marmap's ``r params$data`` dataset.
>
>Should not the phrase rparams$data be within SINGLE backticks ?
>
>Do I misunderstand?
>
>Thank you,
>Ashim
>
>   [[alternative HTML version deleted]]
>
>__
>R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
>https://stat.ethz.ch/mailman/listinfo/r-help
>PLEASE do read the posting guide
>http://www.R-project.org/posting-guide.html
>and provide commented, minimal, self-contained, reproducible code.

-- 
Sent from my phone. Please excuse my brevity.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Installing dyplr on Linux requires a ton of chasing down dependencies

2019-10-14 Thread Collin Lynch
Adam, while I am not familiar with that particular variant of linux,
it sounds like a package manager mismatch in that the ubuntu package
looks for specific libraries which are named differently on your
system.  If you can run a GUI then you have some form of X but the
libraries may be named differently.  It looks like Pop uses apt so you
might try apt-get for R and see if that works or consider compiling
from source.

Collin Lynch.

On Mon, Oct 14, 2019 at 7:36 AM Dirk Eddelbuettel  wrote:
>
>
> Adam,
>
> You may find this blog post and the video instructive:
>
>   http://dirk.eddelbuettel.com/blog/2019/06/09#022_rocker_and_ppas
>
> It illustrates how 'installing tidyverse' (or rstan) can be a single and done
> in under two minutes == on Linux, with the appropriate distribution and
> settings.  In short:  some have binaries prebuilt, some don't.
>
> My blog has a few post in the 'r4' section on that as well as on other
> approaches to this.
>
>   http://dirk.eddelbuettel.com/blog/code/r4/
>
> Now, you choose a somewhat non-standard distro. The price of that choice may
> indeed be that you have to install everything (R/CRAN-related) from source.
>
> Hope this helps, Dirk
>
> --
> http://dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org
>
> __
> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



-- 
ArgLab & Center for Educational Informatics
Department of Computer Science
North Carolina State University

https://research.csc.ncsu.edu/arglab/people/cflynch.html

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] Double / single backticks for inline R code in an Rmarkdown file

2019-10-14 Thread Ashim Kapoor
Dear All,

I am reading this file :-

https://rmarkdown.rstudio.com/lesson-6.html

My query is : In line 14 of the above file, ie.

The [marmap](https://cran.r-project.org/web/packages/marmap/index.html)
package provides tools and data for visualizing the ocean floor. Here is an
example contour plot of marmap's ``r params$data`` dataset.

Should not the phrase rparams$data be within SINGLE backticks ?

Do I misunderstand?

Thank you,
Ashim

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Installing dyplr on Linux requires a ton of chasing down dependencies

2019-10-14 Thread Dirk Eddelbuettel


Adam,

You may find this blog post and the video instructive:

  http://dirk.eddelbuettel.com/blog/2019/06/09#022_rocker_and_ppas

It illustrates how 'installing tidyverse' (or rstan) can be a single and done
in under two minutes == on Linux, with the appropriate distribution and
settings.  In short:  some have binaries prebuilt, some don't.

My blog has a few post in the 'r4' section on that as well as on other
approaches to this.

  http://dirk.eddelbuettel.com/blog/code/r4/

Now, you choose a somewhat non-standard distro. The price of that choice may
indeed be that you have to install everything (R/CRAN-related) from source. 

Hope this helps, Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Installing dyplr on Linux requires a ton of chasing down dependencies

2019-10-14 Thread David Winsemius
Generally problems involving Ubuntu are sent to r-sig-Debian but maybe your new 
OS is not in that heritage. If not, you may get a more informed audience at 
r-devel. (Technically this is more on-topic there than on rhelp.) But you 
should read the Posting Guide, subscribe, post in plain text, and include more 
of the text from the errors. 

David

Sent from my iPhone

> On Oct 13, 2019, at 3:46 AM, Adam Frank  wrote:
> 
> I just got a new Linux computer running Pop!_OS.  If I download R from the
> repository, which is basically he same as on Ubuntu, I get an outdated
> version that can't run ggplot2.  So I went to the R download page and
> downloaded the newest version.  It has make and config files but they
> require an intense number of dependencies and I couldn't figure out how to
> ever get the X11 dependency resolved.  Some places suggested installing
> packages related to xorg, but I didn't find `xorg-x11*` in my package
> manager at all.  I tried installing `xorg-*` but this didn't resolve the
> problem.
> 
> I tried installing Anaconda and doing everything within there.  It delivers
> the latest version of R but still to run `install.packages("dplyr",
> dependencies=T)` throws a ton of errors about unmet dependencies, one of
> which is again X11.  So at this point I'm feeling kind of stuck on this ...
> 
> And it just seems wild to me that it's this hard to get R working with
> dplyr.  Is there an easier way?
> 
> I also tried guessing that maybe `conda install r-dplyr` might do something
> but no luck, package not found.  Might have something to do with
> environments, I'm not really clear on how those work.
> 
> Anyway, for details: My OS is Pop!_OS 19.04, my R version is 3.6.1, RStudio
> 1.1.456 running by way of Anaconda.  Recently ran an update on every R
> package.
> 
>[[alternative HTML version deleted]]
> 
> __
> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Installing dyplr on Linux requires a ton of chasing down dependencies

2019-10-14 Thread WU Degang
Sorry to digress here. Having used CRAN and conda to manage R packages, I find 
that using conda to install R packages will cause more troubles than CRAN. I 
would stick with CRAN.



Sent from Mail for Windows 10




From: R-help  on behalf of Adam Frank 

Sent: Sunday, October 13, 2019 4:46:29 AM
To: r-help@r-project.org 
Subject: [R] Installing dyplr on Linux requires a ton of chasing down 
dependencies

I just got a new Linux computer running Pop!_OS.  If I download R from the
repository, which is basically he same as on Ubuntu, I get an outdated
version that can't run ggplot2.  So I went to the R download page and
downloaded the newest version.  It has make and config files but they
require an intense number of dependencies and I couldn't figure out how to
ever get the X11 dependency resolved.  Some places suggested installing
packages related to xorg, but I didn't find `xorg-x11*` in my package
manager at all.  I tried installing `xorg-*` but this didn't resolve the
problem.

I tried installing Anaconda and doing everything within there.  It delivers
the latest version of R but still to run `install.packages("dplyr",
dependencies=T)` throws a ton of errors about unmet dependencies, one of
which is again X11.  So at this point I'm feeling kind of stuck on this ...

And it just seems wild to me that it's this hard to get R working with
dplyr.  Is there an easier way?

I also tried guessing that maybe `conda install r-dplyr` might do something
but no luck, package not found.  Might have something to do with
environments, I'm not really clear on how those work.

Anyway, for details: My OS is Pop!_OS 19.04, my R version is 3.6.1, RStudio
1.1.456 running by way of Anaconda.  Recently ran an update on every R
package.

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Installing dyplr on Linux requires a ton of chasing down dependencies

2019-10-14 Thread Jeff Newmiller
https://cran.r-project.org/bin/linux/ubuntu/

On October 12, 2019 1:46:29 PM PDT, Adam Frank  
wrote:
>I just got a new Linux computer running Pop!_OS.  If I download R from
>the
>repository, which is basically he same as on Ubuntu, I get an outdated
>version that can't run ggplot2.  So I went to the R download page and
>downloaded the newest version.  It has make and config files but they
>require an intense number of dependencies and I couldn't figure out how
>to
>ever get the X11 dependency resolved.  Some places suggested installing
>packages related to xorg, but I didn't find `xorg-x11*` in my package
>manager at all.  I tried installing `xorg-*` but this didn't resolve
>the
>problem.
>
>I tried installing Anaconda and doing everything within there.  It
>delivers
>the latest version of R but still to run `install.packages("dplyr",
>dependencies=T)` throws a ton of errors about unmet dependencies, one
>of
>which is again X11.  So at this point I'm feeling kind of stuck on this
>...
>
>And it just seems wild to me that it's this hard to get R working with
>dplyr.  Is there an easier way?
>
>I also tried guessing that maybe `conda install r-dplyr` might do
>something
>but no luck, package not found.  Might have something to do with
>environments, I'm not really clear on how those work.
>
>Anyway, for details: My OS is Pop!_OS 19.04, my R version is 3.6.1,
>RStudio
>1.1.456 running by way of Anaconda.  Recently ran an update on every R
>package.
>
>   [[alternative HTML version deleted]]
>
>__
>R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
>https://stat.ethz.ch/mailman/listinfo/r-help
>PLEASE do read the posting guide
>http://www.R-project.org/posting-guide.html
>and provide commented, minimal, self-contained, reproducible code.

-- 
Sent from my phone. Please excuse my brevity.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] Installing dyplr on Linux requires a ton of chasing down dependencies

2019-10-14 Thread Adam Frank
I just got a new Linux computer running Pop!_OS.  If I download R from the
repository, which is basically he same as on Ubuntu, I get an outdated
version that can't run ggplot2.  So I went to the R download page and
downloaded the newest version.  It has make and config files but they
require an intense number of dependencies and I couldn't figure out how to
ever get the X11 dependency resolved.  Some places suggested installing
packages related to xorg, but I didn't find `xorg-x11*` in my package
manager at all.  I tried installing `xorg-*` but this didn't resolve the
problem.

I tried installing Anaconda and doing everything within there.  It delivers
the latest version of R but still to run `install.packages("dplyr",
dependencies=T)` throws a ton of errors about unmet dependencies, one of
which is again X11.  So at this point I'm feeling kind of stuck on this ...

And it just seems wild to me that it's this hard to get R working with
dplyr.  Is there an easier way?

I also tried guessing that maybe `conda install r-dplyr` might do something
but no luck, package not found.  Might have something to do with
environments, I'm not really clear on how those work.

Anyway, for details: My OS is Pop!_OS 19.04, my R version is 3.6.1, RStudio
1.1.456 running by way of Anaconda.  Recently ran an update on every R
package.

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.