The dataframe data1 has variables Year, value, country_name and apy. Variable apy takes three values: “Area", “Yield" and “Production". The scales of Area, Yield and Production are different. To deal with this, I would like to explicitly specify the limits of the scales for Area, Yield and Production in the facet_grid command. These would have to be different for each of them.
How could I possibly do that? Or is there any other way in ggplot to specify (different) limits of scales in different facets.
Vikas
Pete St Marie
unread,
Sep 13, 2016, 9:04:42 AM9/13/16
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to ggplot2
You may want finer control, but...
I don't think there is an issue.
You could try:
scales="free"
you could also try reordering the facet:
country_name~apy
I prefer to let the data speak for themselves. The default extension of
the plot margins make sense. Your code looks fine (except for spaces
etc.). Maybe I don't understand the problem.