File:Healthy Life Years and LEB.svg
Original file (SVG file, nominally 565 × 1,517 pixels, file size: 433 KB)
Captions
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
[edit]DescriptionHealthy Life Years and LEB.svg |
English: Life expectancy and Healthy life expectancy (WHO,2019) |
Date | |
Source | Own work, Data from WHO https://apps.who.int/gho/data/node.main.688 |
Author | Yuasan |
Permission (Reusing this file) |
CC-0 |
Licensing
[edit]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.
http://creativecommons.org/publicdomain/zero/1.0/deed.enCC0Creative Commons Zero, Public Domain Dedicationfalsefalse |
graph data
[edit]import matplotlib as mpl
import matplotlib.pyplot as plt
import pandas as pd
import numpy as np
df = pd.read_csv("data.tsv", index_col=0 , sep = "\t")
df = df.sort_values(by=["Life expectancy"], ascending=True)
x = np.arange(df.index.size)
fig, ax = plt.subplots(figsize=(5, 20))
cmap = mpl.colormaps['tab10']
ax.barh(df.index, df["Life expectancy"] , color=cmap(1) )
ax.barh(df.index, df["Healthy life expectancy"] , color=cmap(2) )
ax.set_axisbelow(True)
plt.rcParams['font.sans-serif'] = ['Noto Sans JP']
plt.rcParams['font.family'] = 'sans-serif'
plt.subplots_adjust(left=0.1, bottom=0.05, right=1, top=0.95)
plt.title("Life expectancy and Healthy life expectancy (WHO,2019)", fontsize=13)
plt.tick_params(labelsize=9, pad=4)
plt.xlabel("year (at birth)", fontsize=9)
plt.yticks(fontsize=7)
plt.ylim(-0.5, len(df)-.5)
plt.xlim([40,90])
ax.legend(df.columns, fontsize=9, ncol=1, loc='lower right', frameon=True, facecolor="#dddddd")
ax.minorticks_on()
plt.grid(which='major',color='#cccccc',linestyle='-', axis="x")
plt.grid(which='minor',color='#cccccc',linestyle='--', axis="x")
plt.subplots_adjust(top =0.85)
plt.savefig("image.svg", bbox_inches='tight')
File history
Click on a date/time to view the file as it appeared at that time.
Date/Time | Thumbnail | Dimensions | User | Comment | |
---|---|---|---|---|---|
current | 12:24, 12 March 2023 | 565 × 1,517 (433 KB) | Yuasan (talk | contribs) | Uploaded own work with UploadWizard |
You cannot overwrite this file.
File usage on Commons
There are no pages that use this file.
File usage on other wikis
The following other wikis use this file:
- Usage on en.wikipedia.org
- Usage on ja.wikipedia.org
Metadata
This file contains additional information such as Exif metadata which may have been added by the digital camera, scanner, or software program used to create or digitize it. If the file has been modified from its original state, some details such as the timestamp may not fully reflect those of the original file. The timestamp is only as accurate as the clock in the camera, and it may be completely wrong.
Width | 452.064844pt |
---|---|
Height | 1213.226875pt |