R-Ladies Sydney Profile picture
Aug 21, 2019 12 tweets 5 min read Read on X
Rebecca ⁦@rlbarter⁩ kicking off by showing how you can present R code from a jupyter notebook #Rstats 👍👍👍
Oooo nice shortcut select your code and then “command I” makes everything nicely aligned! #rstats
The tribble function is a handy way of making a df #rstats - not as handy as datapasta of course but still pretty handy
What is an anonymous function? It is just a function that doesn’t have a name defined. Like a function that you do on the fly. #rstats
the modify function will do the same as map but will simply return the same kind of thing as the input- that seems useful #rstats
Ooo good practice tips... read in the data as data_orig and then make another version called data, that way you always have the original in your environment #rstats
map_chr(df, class) is a nice alternative to str() or summary() to see the class of each variable #rstats
map_dbl(df, n_distinct) gets you how many unique values in each column- nice #Tatar’s
How did I not know about the pluck() function? E.g pluck(1) is the same as [[1]], but you can %>% it! #rstats
Dplyr bonus, distinct(v1 , v2) will give you all the distinct combinations of v1 and v2 #rstats
When using map2 with ggplot, you can glue a title to your plot with + ggtitle(glue::glue(.x, “ “, .y)) #rstats
One more hot tip ... the fancy %<>% will work like df <- df %>% ..... #rstats

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with R-Ladies Sydney

R-Ladies Sydney Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @RLadiesSydney

Apr 22, 2019
#RYouWithMe showcase Day 4:

Unit 2 (Clean It Up) Lesson 1: Cleaning Up Columns
This lesson comes in 3⃣ parts! See thread 👇
Find the link to the lesson in the video descriptions!

#rstats #rladies #dumpdatacamp #rstudio #learntocode
Part 1: How to clean up and rename variable names! Video:
Part 2: How to select subsets of data and change the order of variables! Video:
Read 4 tweets
Apr 18, 2019
You might be looking for R learning resources, especially if you’ve dropped @DataCamp. We’d like to point you to #RYouWithMe!

rladiessydney.org/ryouwithme

Over the coming days, we'll be showcasing the lessons. Stay tuned!

#rstats #rladies #dumpdatacamp
Read 14 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us!

:(