I would like to know if there is a way to replace the label in the x-axis with the value from a different column. Suppose I have this data frame.
Chromosome Value Region
chr1 2 centromere
chr1 2.1 telomere
chr2 2.2 centromere
chr2 1.9 telomere
chr3 2 centromere
chr3 2 telomere
I would like to plot "Region" (x-axis) against "Value" (y-axis), adjust the data point shape according to "Region", but change the x-axis label according to "Chromosome". I tried to plot "Chromosome" against "Value" but the data points become stacked as shown below.
Plotting "Region" against "Value" would create a correct plot but the x-axis label would not be very informative. I want the data points to be to not stack like the figure above. Any tips or help is really appreciated.


dput("your_dataframe")if the data frame is not too large. Best to generate a subset with the absolute minimal data which illustrates your question.