Chat with us, powered by LiveChat Relations among Categorical Variables In the notes on Healy’s Chapter 5, we looked at several ways to visualize the relations - School Writers

Relations among Categorical Variables In the notes on Healy’s Chapter 5, we looked at several ways to visualize the relations

title: "Assignment 1"

output: word_document

## Relations among Categorical Variables

In the notes on Healy's Chapter 5, we looked at several ways to visualize the relationship between two categorical variables.

For this assignment you need to select a pair of cateogrical variables from a dataset which interests you. You could use one of the datasets I used in class, but you are free to pick anything.

## Problem 1

Identify the dataset you've chosen and the two categorical variables. Feel free to create a new categorical variable from an existing quantitative variable. Do a summary of the dataset and produce simple tables for each of the two variables. Make sure that you don't have too many values. Collapse if necessary.

Don't forget to include library commands for all of the packages you need.

“`{r}

# Place your code in this chunk.

glimpse(organdata)

## Problem 2

Select the visualization of the relationship that you feel is the best and produce it.

“`{r}

# Place your code here.

“`

library(ggplot2)

p <- ggplot(data = organdata,

            mapping = aes(x = reorder(country, donors, na.rm=TRUE),

                          y = donors))

p + geom_bar() +

  labs(x=NULL) +

  coord_flip()

## Problem 3

What is your second-choice visualization? Don't forget to explain why you prefer the first choice over the second choice.

“`{r}

# Place your code in this chunk.

“`

library(ggplot2)

p <- ggplot(data = organdata,

            mapping = aes(x = reorder(country, donors, na.rm=TRUE),

                          y = donors))

p + geom_boxplot() +

  labs(x=NULL) +

  coord_flip()

I prefer the first visualization to the second one because it is easier to read and interpret the relationship between data

## Problem 4

Based on your visualizations describe what you see. Assume that you are speaking to a blind person.

Just write your comments here.

With the selected visualization, we can tell the level of organ donations in different countries. Since the visualization for every country is placed side by side, comparison of how organs have been donated across different countries becomes easiert.

    Our website has a team of professional writers who can help you write any of your homework. They will write your papers from scratch. We also have a team of editors just to make sure all papers are of HIGH QUALITY & PLAGIARISM FREE. To make an Order you only need to click Ask A Question and we will direct you to our Order Page at WriteDemy. Then fill Our Order Form with all your assignment instructions. Select your deadline and pay for your paper. You will get it few hours before your set deadline.

    Fill in all the assignment paper details that are required in the order form with the standard information being the page count, deadline, academic level and type of paper. It is advisable to have this information at hand so that you can quickly fill in the necessary information needed in the form for the essay writer to be immediately assigned to your writing project. Make payment for the custom essay order to enable us to assign a suitable writer to your order. Payments are made through Paypal on a secured billing page. Finally, sit back and relax.

    Do you need an answer to this or any other questions?