Analytics Log - Adil Khan

View Original

Create Pyramid Chart in R Using Google Analytics Demographic Report

I came across this tweet that visualized the age/gender data using a pyramid chart in R. Creator >>https://thomas-neitmann.github.io/ggcharts/reference/pyramid_chart.html

With the below script, I’ve taken the main pyramid_chart script by Thomas Neitmann and applied it by using the Google Analytics API for demographic report - using age and gender data to build a similar pyramid.

If you’d like to add additional arguments to the plot, you can via this: https://thomas-neitmann.github.io/ggcharts/reference/pyramid_chart.html#arguments

See this content in the original post