Jump to content

File:Social benefits for elderly in Japan.svg

Page contents not supported in other languages.
This is a file from the Wikimedia Commons
From Wikipedia, the free encyclopedia

Original file (SVG file, nominally 900 × 450 pixels, file size: 126 KB)

This file may be updated to reflect new information.
If you wish to use a specific version of the file without it being overwritten, please upload the required version as a separate file.

Summary

Description
English: Social benefits for elderly in Japan
Date
Source Own work, Data from National Institute of Population and Social Security Research.
社会保障費用統計2022 , https://www.ipss.go.jp/ss-cost/j/fsss-R02/fsss_R02.html
Author Yuasan
Permission
(Reusing this file)
CC-0

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
Creative Commons CC-Zero This file is made available under the Creative Commons CC0 1.0 Universal Public Domain Dedication.
The person who associated a work with this deed has dedicated the work to the public domain by waiving all of their rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law. You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission.

Graph data

import matplotlib.pyplot as plt
import pandas as pd
import matplotlib.ticker as ticker

df = pd.read_csv("data.tsv", index_col=0 , sep = "\t")
df = df.fillna(0).div(1000, fill_value=0).fillna(0)

df1 = df.drop('Total of Social Benefit', axis=1).T
df2 = df.reindex(columns=['Total of Social Benefit'])

fig, ax = plt.subplots(figsize=(10, 5))
ax2 = ax.twinx()

ax.plot(df2, label="Total of Social Benefit", color="#5E95CD")
ax.fill_between( df2.index ,0, df2['Total of Social Benefit'].values,  color="lightblue", alpha=0.5)

for i in range( len(df1) ):
	ax2.bar(df1.columns, df1.iloc[i] , width=1, bottom=df1.iloc[:i].sum(), label=df1.index[i])

lines, labels = ax.get_legend_handles_labels()
lines2, labels2 = ax2.get_legend_handles_labels()
ax2.legend(lines + lines2, labels + labels2, facecolor="#eeeeee" ,ncol=2, fontsize=12,loc='upper left')

ax.set_ylim([0,1400])
ax2.set_ylim([0,1400])

plt.rcParams['font.family'] = 'sans-serif'
plt.rcParams['font.sans-serif'] = ['Noto Sans Display']
plt.subplots_adjust(left=0.07, bottom=0.07, right=0.98, top=0.91)

plt.title("Social benefits for elderly in Japan (IPSS,2022)", fontsize=20)
plt.tick_params(labelsize=10, pad=4)
ax.set_ylabel("hundred billion JPY", size=12)

plt.setp(ax.get_xticklabels(), fontsize=8, rotation=75)
plt.setp(ax.get_yticklabels(), fontsize=9 )
ax.xaxis.set_major_locator(ticker.MultipleLocator(2))
ax.yaxis.set_major_locator(ticker.MultipleLocator(250))

ax2.set_yticklabels([])
ax2.set_yticks([])

ax.minorticks_on()
ax.set_axisbelow(True)
ax2.set_axisbelow(True)
ax.grid(True, which='major',color='#cccccc',linestyle='-', axis="y")
ax.grid(True, which='minor',color='#eeeeee',linestyle='--', axis="y")
ax2.grid(None,which='major')

plt.savefig("image.svg")
Any autoconfirmed user can overwrite this file from the same source. Please ensure that overwrites comply with the guideline.

Captions

Social benefits for elderly in Japan

Items portrayed in this file

depicts

20 April 2023

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current12:12, 20 April 2023Thumbnail for version as of 12:12, 20 April 2023900 × 450 (126 KB)YuasanUploaded own work with UploadWizard

The following page uses this file:

Global file usage

Metadata