jmbejara / comp-econ-sp18

Main Course Repository for Computational Methods in Economics (Econ 21410, Spring 2018)
16 stars 23 forks source link

Chipotle R HW #68

Closed afgong closed 6 years ago

afgong commented 6 years ago

What would be the function in R to describe how the dataset is indexed?

jmbejara commented 6 years ago

The point here is that R data.frame objects don't display an explicit index. This is a difference between Pandas and the base R data.frame

mcatalay commented 6 years ago

Hi Jeremy, So when we're trying to get the info for the chipotle data frame, does our output in R have to look like the result in python or can we have multiple lines of code produce the same information as .info did in python?

Also in questions where it wants us to use groupby and pivot_tables do we have to do both again or just do it once by a method in R.? If so, how do pivot tables in r?

jmbejara commented 6 years ago

Hey! No worries trying to match the look. Also, you don't have to replicate the information from .info(). That information will be harder to find. With that one particular question, you can just give some basic information mostly of your choosing.

Oh, right. I meant to make a comment about that. Feel free to just use group_by. I don't think that dplyr has a "pivot_table" function.