Enhanced scatterplot : Side plots in ggplot2 using geom_*side^() of ggside package

Pubblicato il: 19 maggio 2023
sul canale di: Rajendra Choure
384
13

#rprogramming #datavisualization #ggplot2 #ggside #sideplots #marginalplots

In this video I have demonstrated the use of geom_^side^ to get different side plots to enhance scatterplot by showing the distribution of the numeric variable.

#code

library(ggside)

head(iris)

library(ggplot2)

ggplot(iris,aes(Sepal.Length,Petal.Length,fill=Species, color=Species))+
geom_point()+
geom_xsideboxplot()+
geom_ysidedensity(alpha=0.3)+
theme_classic()+
theme(ggside.panel.scale=0.3, legend.position = "bottom")

ggplot(iris,aes(Sepal.Length,Petal.Length,fill=Species, color=Species))+
geom_point()+
geom_xsidebar(alpha=0.3)+
geom_ysidehistogram(alpha=0.3)+
theme_classic()+
theme(ggside.panel.scale=0.3, legend.position = "bottom")


library(ggside)

head(iris)

library(ggplot2)

ggplot(iris,aes(Sepal.Length,Petal.Length,fill=Species, color=Species))+
geom_point()+
geom_xsideboxplot()+
geom_ysidedensity(alpha=0.3)+
theme_classic()+
theme(ggside.panel.scale=0.3, legend.position = "bottom")

ggplot(iris,aes(Sepal.Length,Petal.Length,fill=Species, color=Species))+
geom_point()+
geom_xsidebar(alpha=0.3)+
geom_ysidehistogram(alpha=0.3)+
theme_classic()+
theme(ggside.panel.scale=0.3, legend.position = "bottom")

Facebook page:
  / rajendrachoureisc  

Mail Id:
rajuchoure@gmail.com

youtube playlist:
   • R programming tutorials  


In questa pagina del sito puoi guardare il video online Enhanced scatterplot : Side plots in ggplot2 using geom_*side^() of ggside package della durata di ore minuti seconda in buona qualità , che l'utente ha caricato Rajendra Choure 19 maggio 2023, condividi il link con amici e conoscenti, su youtube questo video è già stato visto 384 volte e gli è piaciuto 13 spettatori. Buona visione!