Question: R studio Consider the two tables shown below called bands and instruments. bands: name lastname band year Mick Jagger Stones 1962 John Lennon Beatles 1960

R studio

Consider the two tables shown below called bands and instruments.

bands:

name

lastname

band

year

Mick

Jagger

Stones

1962

John

Lennon

Beatles

1960

Paul

McCartney

Beatles

1960

Paul

McCartney

Wings

1971

instruments:

artist

artistname

plays

model

John

Lennon

guitar

Gibson

Paul

McCartney

bass

Hofner

Keith

Richards

guitar

Fender

Paul

McCartney

bass

Hofner

Draw the output table from the following operations (you should be able to calculate the output by hand though you may use R to check your answers).

  1. bands %>% inner_join(instruments) [Hint: this is a trick question!]

  1. bands %>% inner_join(instruments, by=c(name="artist"))

  1. bands %>% inner_join(instruments, by=c(name="artist", lastname="artistname"))

  1. bands %>% left_join(instruments, by=c(name="artist", lastname="artistname"))

  1. bands %>% inner_join(instruments, by=c(name="artist", lastname="artistname", year="plays"))

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!