Question: This code, found online, returns with various errors. Can you help me fix this? The prompt is: Step 5: Create a map of the U.S.,

This code, found online, returns with various errors. Can you help me fix this? The prompt is:

Step 5: Create a map of the U.S., with the color of the state representing the state population L) Make sure to expand the limits correctly and that you have used **coord_map** appropriately.

dfSimple$region <- tolower ( dfSimple$state ) theUS <- merge ( states , dfSimple , region = region ) the US %> % ggplot ( ) + geom_polygon ( aes ( x = long , y= lat , group = group , , fill = theUS$population ) ) + coord_map ( )

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!