Question: The variables in the data set are: Variable | Description ---------|------------ `year` | the year of the birth `month` | the month of the birth

 The variables in the data set are: Variable | Description ---------|------------

The variables in the data set are:

Variable | Description ---------|------------ `year` | the year of the birth `month` | the month of the birth `state` | the state where the birth occurred, including "DC" for Washington D.C. `is_male` | which is `TRUE` if the child is male, `FALSE` otherwise `weight_pounds` | the child's birth weight in pounds `mother_age` | the age of the mother `child_race` | race of the child. `plurality` | the number of children born as a result of the pregnancy, with 1 representing a single birth, 2 representing twins, etc. `region` | the region of the US that the state is part of `state_color` | the political "color" of the state: red, blue, or purple

Need to know code to generate this, thanks!!!

221 222 Create a data frame called "colorGender' that gives the counts, the mean weight of babies and the mean age of mothers for each combination of the four levels of "state_color" and the two levels of 'is_male'. 223 224{r} 225 226

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!