What They Forgot to Teach You about R Workshop - rstudio::conf 2020

What They Forgot to Teach You about R Workshop

1/27/20—1/28/20
9:00 AM-5:00 PM
2 Day Workshop

Jenny Bryan
Software Engineer
RStudio

Jim Hester
Software Engineer
RStudio

Kara Woo
Sage Bionetworks


This is a two-day hands on workshop designed for experienced R and RStudio users who want to (re)design their R lifestyle. You’ll learn holistic workflows that address the most common sources of friction in data analysis. We’ll work on project-oriented workflows, version control for data science (Git/GitHub!), and how to plan for collaboration, communication, and iteration (incl. RMarkdown).

In terms of your R skills, expect to come away with new knowledge of your R installation, how to maintain it, robust strategies for working with the file system, and ways to use the purrr package for repetitive tasks.

You should take this workshop if:

  1. You’ve been using R for a while and you feel like writing R code is not what’s holding you back the most.
  2. You’ve realized that you have more pressing "meta" problems that no one seems to talk about:
  3. You want to know how to divide your work into projects and scripts, how to expose your work to others, and how to get more connected to the R development scene.

The tidyverse is not an explicit focus of the course (other than the purrr segment) and you can certainly work through the content without it. But you should expect a great deal of tidyverse exposure.

1 Like

This post describes pre-workshop setup necessary for the workshop:

What They Forgot to Teach You About R
at rstudio::conf 2020
January 27-28, 2020
Golden Gate Rooms 4-5 (Lobby Level)

It's all about Git + GitHub + RStudio (the pre-workshop setup, that is).

This truly requires your attention before the morning of January 27th. We want to show you how to use Git/GitHub in your life as an R-using data analyst, which means we can't afford to get bogged down in a hot mess of Git installation issues. Let's try to work through them beforehand.

Do what's listed here: Chapter 3 Workshops | Happy Git and GitHub for the useR

This is the thread to use if you need some help.

If you wonder why we've chosen to include Git/GitHub in this workshop, you might want to read Excuse me, do you have a moment to talk about version control?.

Go forth and install Git! :boom:

Hello, I wanted to flag a challenge I have had in preparing for next week's workshop.

The shortest version of the story is that I am unable to "click the Git tab" in RStudio as directed in section 12.4 of the instructions as there is no Git tab in my RStudio.

The longer version is that I wonder if it has something to do with my network security on my computer. I had no issues with the setting up as per the pre-workshop instructions through to "Prove local Git can talk to GitHub" which is where I ended on Wednesday. On Thursday, however, I was unable to connect to GitHub through RStudio and subsequently realized that I also wasn't able to connect through the shell as I had been the day before. The error presented was:

$ git remote show origin
fatal: unable to access 'https://github.com/MatthewHogel/myrepo.git/': SSL certificate problem: self signed certificate in certificate chain

When disconnected from my network, the problem resolved itself. I'm not sure why it worked one day and not the next, but my computer was put through a force restart in between so network or OS settings may have been changed/updated.

So I am now in a position where I can create an environment where R and Git can communicate to GitHub (off my work network), however there is no Git tab to allow me to push and pull through RStudio.

RStudio is pointed properly to Git based on what is shown in Tools > Global Options. The PAT is '' and R has a path stored.

I have started troubleshooting using what's been discussed online, however there is a lot of content which makes me think that this is a problem that has been solved before, and although I haven't found anything that has worked, since this workshop has been run many times before I figured there may be a go-to solution known from your end.

Looking forward to the workshop.
Matt

Update: I believe I have solved the problem.

I didn't think I needed to set up an SSH key because I wasn't challenged for username and password information the second time I pushed to GitHub, however adding the SSH key seems to have corrected things. We will see if it works tomorrow.

Hi Matt! I'm glad it sounds like things are resolved. I haven't run into this specific issue before, but it does sound like your theory about it being network-related is likely. If it's working now, then I wouldn't worry too much about it, and if you run into any issues at the conference we can look into it further then. Let me know if you have any other questions!

Hi there,
I'm having some trouble at the "introduce yourself to Git" stage of the setup. I've updated RStudio, installed Git for windows, changed my settings in RStudio tools so that new terminals open up with Git Bash. I open a new terminal in RStudio and type where git and get C:\Program Files\Git\bin\git.exe This all seems good. I then type git config --global user.name 'Jane Doe' and get the following error:
bash: git: command not found
I checked my PATH by typing $echo $PATH into the terminal and I get a bunch of stuff mainly from Program Files. Git is not listed. This leads me to believe my PATH is dysfunctional. I saw the directions in Chapter 14 about Git/GitHub/Rstudio hell (http://www.troubleshooters.com/linux/prepostpath.htm) but I'm a little lost at this point. I found a .bash_profile.sh file, but I'm not sure how to make sense of it (I'm totally new to Git). Help appreciated! Thanks so much.
Monique

Hi Monique! Thanks for posting your question here. Just to double check, when you installed Git for Windows, did you see this dialog box, and if so did you check "Git from the command line and also from 3rd-party software"?

Also, in RStudio, if you go to Preferences -> Git/SVN, what do you see where it says "Git executable"? Does it show C:/Program Files/Git/bin/git.exe? If not, try adding that (and restart RStudio for good measure).

If this doesn't work, let me know and we'll keep trying :slight_smile:

Hi Kara, Thank you for your help. Yes, I saw and checked the box "Git from the command line and also from 3rd-party software", and I also double checked that it shows C:/Program Files/Git/bin/git.exe under "Git executable". SVN executable is blank. I'll keep exploring!
Thanks again.
Monique

Hi again Kara! I think I got it. I rebooted my system in between emails and somehow it worked. Maybe I just needed to restart RStudio... In any case, I was able to configure my user name and email and when I type $ git config --global --list the correct name and email show. Thanks! I'll let you know if I run into any other weird behavior.
Monique

Great! Glad it's working now.

I have a challenge with Git config. I am using a window system and have also downloaded Git.

The which git and where git output are as follows:

$ which git
/cmd/git

$ where git
C:\Program Files\Git\cmd\git.exe

It's taking cmd by default but I want to use bash. How can I change?

I am having the same problem. I have installed git, and it is in the same C:/Program Files/Git/bin directory. I note there is another one in the C:/Program Files/Git/mingw65/bin. That second one is the one that comes up when I type 'which git' in the shell.
In any case, no matter how many times I restart R-studio, reboot my system, or change the directory (I have tried both repeatedly), I cannot open a new project with Git - it just says Git is not installed.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.