I want to make a simple barchart using data from Döring & Poeschl 2019 paper about how sexual relationships between humans and robots are represented in fictions, but I can't figure it out - I think I am missing something really obvious - or perhaps I organised the data badly or I just don't know about an option? The raw data isn't available so I'm using percentages from Table 3 in the paper. I want to show the relative distribution of male/female and heterosexual/homosexual/other for humans and for robots so I can compare with my own data about how humans and robots are represented in fictional media.
Döring, N., Poeschl, S. Love and Sex with Robots: A Content Analysis of Media Representations. Int J of Soc Robotics 11, 665–677 (2019). https://doi.org/10.1007/s12369-019-00517-y
I'm struggling to figure out the best way to actually show this information, simple as it seems. The raw data isn't available but I took the percentages for fictional humans and robots' gender and sexuality from Table 3 in Döring and Poeschl's paper - here it is as a dataframe in R:
sexbots <- structure(list(
Variables = c("Female", "Male", "Child", "Adult", "Elderly",
"Heterosexual", "Homosexual", "Other"),
Human = c(43, 62, 27, 57, 2, 78, 21, 1),
Robot = c(46, 55, 23, 55, NA, 78, 21, 1)),
row.names = c(NA, -8L),
class = c("tbl_df", "tbl", "data.frame"))
> sexbots
# A tibble: 8 × 3
Variables Human Robot
<chr> <dbl> <dbl>
1 Female 43 46
2 Male 62 55
3 Child 27 23
4 Adult 57 55
5 Elderly 2 NA
6 Heterosexual 78 78
7 Homosexual 21 21
8 Other 1 1
Note that the values are percentages not absolute numbers.
I can make a basic bar chart like this - I used geom_col()
instead of geom_bar
so it'd use the existing values rather than counting instances.
sexbots %>%
filter(Variables == "Female" | Variables == "Male") %>%
ggplot() +
geom_col(aes(x = Variables, y = Human, fill = "Variables" ))
But how would I colour the columns so they are different for male or female? And how could I include the data on sexuality in the same chart without it looking silly?
Probably my real question is what is the best way to visualise this data? Perhaps even the way I made the dataframe is less than optimal? Is there a different way I could have dealt with the data about gender, sexuality and age in fictional media from Table 3 of Döring & Poeschl 2019?