Skip to content

Instantly share code, notes, and snippets.

@drj11
Last active March 10, 2016 15:26
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save drj11/f8b5353610789e1f8f36 to your computer and use it in GitHub Desktop.
Save drj11/f8b5353610789e1f8f36 to your computer and use it in GitHub Desktop.
R code cafe notes

no-one is using the etherpad.

by 1745 (15 minutes in) some people had made a plot, most people downloading and installing.

by 1800 (30 minutes in), many people have a plot.

installing on arch and gentoo is hard (arch user gave up installing Rstudio and used command line; gentoo user had to use VNC!). Installing on Ubuntu was hard too.

Someone asked "what does pch=1 do?" (in the call to legend)

On Windows, setting the language to Greek means the Rstudio installer has all the wrong characters. much emojibake. seems to work though!

Wifi. one person found it unreliable. Didn't seem particularly fast for anyone.

If using a version of R < 3.2 then the mirrors don't generally carry packages for older versions. So you're SOL.

When specifically asking people for verbal feedback the general responses were that it was helpful, friendly, nice format. Many people wanted more (quite a few without prompting asked if it was running next week at the same time). When specifically asked what did people want more of the responses were: more R (twice); pandas; iceberg; SPSS; bring-our-own-data.

We should've made a guest list and ticked people off (if only to get accurate numbers)

@mikecroucher
Copy link

A Mac user had lots of versions of R installed. When we installed RStudio, it failed. because this...

https://support.rstudio.com/hc/en-us/articles/206188768-Startup-error-on-OS-X-ERROR-r-error-4-R-code-execution-error-

@jezcope
Copy link

jezcope commented Mar 10, 2016

There's a user package rstudio-desktop-bin for arch, but you need to be comfortable with makepkg to make it work. I seem to remember it working ok for me, but can double check when I get home. Could always build it in advance and have it ready on a USB stick in case anyone needs it?

@willfurnass
Copy link

Q: Any diff between <- and = for assignment? Both used in session materials. A: No diff if assigning outside a function arg. <- preferred for legacy reasons.

Q: Any diff between single and double quotes. Both used in session materials. A: Seems that no difference between single and double quotes (but obvs need them to match). People tend to only use single quotes around single chars.

library(help=datasets) raises error if library help pane in RStudio is too narrow (as was the case for one student where she had RStudio on one side and session material on other side of a small screen.

Gentoo user was connecting to Gentoo from Surface using VNC. Only had problems because help couldn't fire up Firefox as was tied to another Firefox session. This chap was happy enough and accepted that his means for accessing RStudio was unconventional:)

Two students wanted to place the legend outside the plotting area. They found two different solutions on Stack Overflow, one being more concise, the other offering a cleaner separation of concerns.

ToothGrowth exercise can result in unexpected plots as students not told which var to use to colour points. If plot the factor ToothGrowth$supp on the x axis then get a box plot rather than scatter plot. Might be a good idea to say in instructions "try plotting ToothGrowth$dose vs ToothGrowth$len then ToothGrowth$supp vs ToothGrowth$len; why are these plots different?"

Three students (!) asked whether R would be useful for visualising/analysing CFD outputs (two asked about Fluent, another OpenFoam). A colleague of mine (the Gentoo chap; see above) tells me that Fluent has good in-built tools for visualising results in 2D or 3D. AFAIK OpenFoam is a just computation engine (not an integrated analysis environment with GUI) so R may be more useful here. However, I couldn't find any mention of OpenFoam on CRAN, looks like OpenFoam has its own file format and the OpenFoam site points people towards using Paraview for visualising outputs.

If decide to keep using Etherpad (I vote we do so for at least another sessinon) we should include the feedback link at the start (and I need to remember to check the Etherpad and prompt people to leave feedback!)

@jezcope
Copy link

jezcope commented Mar 10, 2016

From memory, Paraview is based on VTK which has well-developed Python bindings — Python might be a better option for the OpenFOAM users.

@AnalytiClaire
Copy link

I had similar questions about formatting, essentially it came down to personal preference and as Will said, legacy

Many people asking if the session would be run again. Since there will be people coming from a large array of backgrounds, it might be worth eventually thinking about more focused, research area-specific/language-specific sessions - one guy offered to help if a similar session was run on C++

Some housekeeping problems - power source was an issue, but Mike mentioned that could be rectified. Also, I thought we could steal an idea from software carpentry to employ the 'pink sticky' system - hand out bright post-its that people can stick to their laptops and flag us down. Might work well considering I was relying on spotting puzzled facial expressions. Also, table spacing wasn't great to navigate, but not impossible.

Considering some people didn't notice they had to download R studio as well as R, I'm not surprised they didn't use the etherpad. They probably didn't even notice! Software carpentry tried to get us to use it but we didn't take to it. I think it can be intimidating interacting on a "public" platform. Might need to give a brief intro on how it works

@willfurnass
Copy link

Q: What are integers shown when do str(dataset$someFactor? A: when a categorical variable is encoded as a factor then each of the valid values that the factor can take is mapped to an integer and only this integer is stored per observation (partly for efficiency reasons).

We should revisit factors in a later session and aim to cover things like setting factor levels, factor ordering and converting factors to numeric or character vectors.

@drj11
Copy link
Author

drj11 commented Mar 10, 2016

I liked the fact that the materials were on github (using it as a publishing platform, essentially), and no ones seemed to notice or care.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment