Entering edit mode
2.2 years ago
Amr
▴
180
I did ggplot2 graph on R, the data is combined 2 dataframes, the plot has many 2 columns with same color each column representing each dataframe, the problem is each 2 columns for 2 dataframes has same colors but outlined with thin color, how to shade the data for one dataframe so that both same colors but one shaded one not shaded ?
df$Cell_lines = 'cell_one'
data2$Cell_lines = 'cell_two'
df3=rbind(df,data2)
ggplot(df3, aes(x=Variant_Classification, y=Number_of_Genes,col =Cell_lines,fill = Variant_Classification)) +
geom_bar(stat="identity",position = 'dodge') + theme_minimal() + labs(title ="cell_one vs cell_two")+
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank())
Provide an example of what your code generates and what you'd like it to generate. You'll get much quicker help that way.
The plot for example has 6 columns, 3 for every dataframe, 2 red, 2 blue, 2 purple, one red outlined with green for dataframe1 and one red outlined with yellow for dataframe 2, one blue outlined with green for dataframe 1 and one blue outlined with yellow for dataframe 2, etc... its not clear like that so I want to make it one red and one red but shaded with black, one blue and one blue shaded with black etc..... in case if you have different idea, its good also. Thanks