plot_treemap: Create treemap plot

View source: R/plot_treemap.R

plot_treemapR Documentation

Create treemap plot

Description

Create treemap plot

Usage

plot_treemap(data, area, fill, subgroup, title, subtitle, data_source)

Arguments

data

data frame

area

numeric data to be plotting

fill

categorical data

subgroup

categorical data (optional)

title

character title

subtitle

character subtitle

data_source

character data source

Value

ggplot objek

Examples

## Not run: 
library(ggplot2)
library(dataplot)

df <- G20
plot_treemap(data = df,
             area = "gdp_mil_usd",
             fill = "region",
             subgroup = "country",
             title = "Lorem Ipsum is simply dummy text",
             subtitle = "Contrary to popular belief, Lorem Ipsum is not simply random text",
             data_source = "www.kedata.online"
             )

plot_treemap(data = df,
             area = "gdp_mil_usd",
             fill = "region",
             subgroup = "country",
             title = "Lorem Ipsum is simply dummy text",
             subtitle = "Contrary to popular belief, Lorem Ipsum is not simply random text",
             data_source = "www.kedata.online"
             )

## End(Not run)

eppofahmi/dataplot documentation built on Jan. 22, 2025, 1:14 a.m.