Skip to main content
Statistics LibreTexts

A.7: Install R Commander

  • Page ID
    45302
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

    ( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\id}{\mathrm{id}}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\kernel}{\mathrm{null}\,}\)

    \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\)

    \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\)

    \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)

    A quick guide about how to install R Commander onto your computer (LDE). You must have R installed and working correctly before proceeding to install the R Commander package. Click here to get the Install R guide.

    Note:

    If you plan to run R in the Cloud, you cannot install the R Commander package, which must be part of a local development environment.

    Installation guides quickly become outdated. This page was last updated 15 August 2021 and describes working installation protocols at that time.

    For BI311, we also use R Commander

    R Commander is a package that adds function to R; it provides a familiar point-and-click interface to R, which allows the user to access functions via a drop-down menu system (Fox 2017). Thus, instead of writing code to run a statistical test, Rcmdr provides a simple menu driven approach to help students select and apply the correct statistical test. R Commander also provides access to Rmarkdown and a menu approach to rendering reports.

    To install R Commander, enter the following code at the R prompt.

    install.packages("Rcmdr")

    In addition, download and install the following plugin:

    install.packages("RcmdrMisc")

    Note: You can combine requests as follows:

    install.packages("Rcmdr", "RcmdrMisc", dependencies=TRUE)

    Adding “dependencies=TRUE” will also install other packages that Rcmdr needs (which would get downloaded once you start Rcmdr for the first time).

    If you have not set a mirror site, you’ll be prompted to do so before you can download and install packages. I recommend 0-Cloud as default mirror site. Be advised: because our university shares a single public IP address, you may experience download delays if we all try to use the same mirror site at the same time.

    To start R Commander, load the packages via the library() command.

    library(Rcmdr)

    Follow installation prompts. You can skip adding the “otools,” for now. However, Rcmdr will prompt you to install otools every time you start, so go ahead and install them at your convenience.

    Mac users: To improve Rcmdr performance you must turn off “app nap.” From Rcmdr, go to Tools, then select “Manage Mac OS X app nap for R.app …” Once you select “off” (click OK to apply), restart Rcmdr, the delay will be removed. Windows 10 folks don’t have to contend with nap.

    Add pandoc and LaTex support

    To complete your R Commander installation you’ll want to add additional document handling software support by adding LaTex and pandoc. In Rcmdr, select Tools, then Install Auxillary Software. Click OK, which will open links in your default browser to download pages for LaTex and pandoc. Download the files, follow the installation instructions for pandoc and LaTeX, then restart R and Rcmdr.

    Here are direct links to the files, plus installation notes:

    LaTeX

    • MikTeX from https://miktex.org/download for Windows systems
    • MacTeX from https://www.tug.org/mactex/ for MacOSX
      • Note the full installation is 4Gb. This is definitely overkill, but does provide all of the tools you could ever need. Other alternatives with smaller downloads require knowledge about what components are needed. So, in short, go for the large download, it’s a simpler choice.
      • Be also advised: If you are running macOS before 10.14, you will have to jump through additional hoops to get macTeX installed.

    pandoc

    Windows 10/11

    https://github.com/jgm/pandoc/releases/download/2.14.1/pandoc-2.14.1-windows-x86_64.msi

    MacOS

    https://github.com/jgm/pandoc/releases/download/2.14.2/pandoc-2.14.2-macOS.pkg

    Test Rcmdr

    Figure \(\PageIndex{1}\) shows a basic R Commander session. Enter code in the script window (1), click on the Submit button to run the code, and results show up in the output window (2).

    fig-ch01_patchfile_01.jpgScreenshot of basic R Commander session on WinPC. Code is entered in a script window, labeled window 1, and results appear in the output window, labeled window 2.
    Figure \(\PageIndex{1}\): Screenshot of basic R Commander session on WinPC.

    Click on R Markdown tab, edit (e.g., replace with your own title and name), then click on the Generate Report button to create a pdf of your work, default file name is RcmdrMarkdown.pdf (Fig. \(\PageIndex{2}\)). If you do not have pandoc and LaTeX properly installed, then only an HTML document will be available as an option.

    Screenshot of a portion of RcmdrMarkdown.pdf, showing title, name, date, code to plot a data set, and the resulting scatter plot.
    Figure \(\PageIndex{2}\): Screenshot of a portion of RcmdrMarkdown.pdf.

    This page titled A.7: Install R Commander is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by Michael R Dohm via source content that was edited to the style and standards of the LibreTexts platform.

    • Was this article helpful?