Duplicate axis for a R plot

0 votes
how to add duplicate axis as a dual axis for a ggplot? I want to add a mirror to the y-axis.
Jul 25, 2019 in Data Analytics by karthick

edited Jul 25, 2019 1,497 views

1 answer to this question.

0 votes
Add duplicate axis using dup.axis attribute like below.

Ex:

> plot + scale_y_continuous(sec.axis = dup_axis())
answered Nov 4, 2019 by radha

Related Questions In Data Analytics

0 votes
1 answer

R - Error: Duplicate identifiers for rows

You can try the below code as ...READ MORE

answered Apr 9, 2018 in Data Analytics by kappa3010
• 2,090 points
2,716 views
0 votes
2 answers

R function for finding the index of an element in a vector?

The function match works on vectors : x <- sample(1:10) x # ...READ MORE

answered Dec 12, 2020 in Data Analytics by Rajiv
• 8,910 points
55,987 views
0 votes
1 answer

Save a plot as image on the disk using R

Consider for both the situations: 1. Image will ...READ MORE

answered Apr 14, 2018 in Data Analytics by Sahiti
• 6,370 points
1,808 views
0 votes
1 answer

How to wait for a keypress in R?

It is easy by using readline readline(prompt="Press any ...READ MORE

answered Apr 25, 2018 in Data Analytics by DeepCoder786
• 1,720 points
1,442 views
0 votes
1 answer
0 votes
0 answers

Chart/plot to show 3 dimensions in a chart - R

Hi, I want to show chart with ...READ MORE

Jul 12, 2019 in Data Analytics by kalyan
377 views
0 votes
1 answer

Add secondary axis as a dual axis in R plot

You can add a secondary axis in ...READ MORE

answered Nov 4, 2019 in Data Analytics by keerthi
1,776 views
0 votes
0 answers

Edit date values in ggplot line chart -R

Hi, I want to edit the data ...READ MORE

Jul 25, 2019 in Data Analytics by rekha
340 views
0 votes
1 answer

Change the order of legend values in a plot in R

@prardhana, Use scale_fill/color/size_discrete/contin....(labels = c()). compare both to see ...READ MORE

answered Nov 4, 2019 in Data Analytics by payal
1,765 views
0 votes
2 answers

Transforming a key/value string into distinct rows in R

We would start off by loading the ...READ MORE

answered Mar 26, 2018 in Data Analytics by Bharani
• 4,660 points
813 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP