Comments (13)
This is also something we have discussed in our group, since we rarely have time to make it through all of the code in Data Wrangling with tidyr. And this is a problem since the last part is crucial for continuing with Data Visualisation.
I think the tidyr part could be trimmed down by removing the example of making the respondent_wall_type
wider (it's unrealistic that you would want to do this anyway). Instead add a step-by-step walkthrough of pivoting items_owned
wider. Then maybe add an exercise to do the same to months_lack_food
just to make sure the process is clear to the learners.
Pivoting months_lack_food
could also be dropped completely since it's not used in subsequent episodes.
from r-socialsci.
@juanfung sure! I'll see what I can come up with. On this branch https://github.com/bbartholdy/r-socialsci/tree/tidyr-adjust (for anyone interested).
from r-socialsci.
Hi, sorry I disappeared, I got caught up in my work. I would like to collaborate with this section of the lesson, are you developing an alternative?
from r-socialsci.
Hi @msquiroga89, no worries! Yes, I am working on modifications to the episode. It's tricky because it still needs to align with the next episode on data visualisation. My plan was to add a step-by-step walkthrough of pivoting items_owned
wider, instead of respondent_wall_type
(since it's doesn't really make sense and actually makes the data 'untidy') . items_owned
is the only modified variable that is actually used in a later episode (as far as I can tell). It might also be nice to add an exercise, maybe on months_lack_food
.
Let me know what your thoughts are.
from r-socialsci.
@bbartholdy @msquiroga89 just checking in on this issue...let us (maintainers) know if you need any help!
Thanks @juanfung! I hit a bit of a busy period but should be able to pick it up again after next week.
from r-socialsci.
It sounds like a local problem, I didn't have any issues, including on a fresh Ubuntu install. I know there were problems with some previous versions of {renv}, so maybe worth updating? It might also be an issue with the way the workbench uses {renv}, but I also don't really know enough about it.
from r-socialsci.
@msquiroga89 thank you that's great feedback! would you be interested in submitting a PR or providing some suggestions to improve the illustration of the two functions?
from r-socialsci.
Per discussion with @eirini-zormpa perhaps make this section optional, in addition to improving the example
from r-socialsci.
@bbartholdy these are great suggestions! i have assigned this issue to myself, but if you are willing to submit a PR with these suggestions, it would be super appreciated :)
from r-socialsci.
@bbartholdy @msquiroga89 just checking in on this issue...let us (maintainers) know if you need any help!
from r-socialsci.
@bbartholdy no worries, that sounds good and your contributions are much appreciated!
from r-socialsci.
I have reorganised the episode as discussed above. I had to deviate a bit from the original plan in order for the episode to make sense (bbartholdy@a9182ce).
To summarise:
- The transformation of
respondent_wall_type
has been removed - There is, instead, a step-by-step guide to transform
items_owned
- The transformed
items_owned
data frame is used to demonstratepivot_longer
- Exercises now involve creating summary tables from the longer data frame (to demonstrate how it differs from the wider format)
- Creating
interviews_plotting
is now directly integrated in the episode (before it seemed more like an afterthought)
Still needed:
- The figures showing the reshaping of
respondent_wall_type
need to be updated to depictitems_owned
- ??? an optional exercise at the end could be going back to the original data frame. This would involve introducing
reframe()
I wanted to get some input on the new layout before changing the figures (@juanfung , @msquiroga89 ?).
from r-socialsci.
@bbartholdy thank you for the incredible amount of work you've done on this! apologies for not replying sooner, but i finally had a chance to serve your changes locally and have two comments:
- this is a fantastic new layout and i support modifying the accompanying figures
- when i serve locally, i am getting the following error:
Error in separate_longer_delim(., items_owned, delim = ";"): could not find function "separate_longer_delim"
i checked and i have tidyr 1.3.0 installed, so i'm puzzled. i'm not well versed in how workbench works, and whether there is a local environment enforcing package versions (but if there were, i wouldn't be getting an error). just flagging to make sure you double check this all works as intended. i am guessing it's a local problem on my end, but can't figure it out
from r-socialsci.
Related Issues (20)
- Mention other packages for creating tables HOT 4
- change in dplyr 1.1.0 HOT 1
- Managing conflicts HOT 2
- Cleaner SAFI_clean dataset HOT 6
- JSON data links
- JSON episode: Write the JSON file to csv needs reworking HOT 5
- Connecting to the RStudio GUI HOT 2
- Quarto is the new R Markdown HOT 6
- the "IMPORTANT NOTE" callout obscures code boxes in some lessons (example: Lesson 6: R Markdown) HOT 3
- Replace superseded separate_rows() function HOT 4
- Suggestion to update package cache HOT 1
- Recommended updates to handouts HOT 3
- Adding some information to the Before we start episode (R for Social Scientists) HOT 4
- Restructure instructor notes HOT 1
- Confusing library installation instructions HOT 4
- Problems with geom_jitter() for numeric columns HOT 5
- Broken link to dataset description HOT 2
- Fix typos in text and improve clarity HOT 1
- Tidyverse/Lubridate automatically loaded alongside other packages HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from r-socialsci.