File:Covid-19-rokotukset 1.svg

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

Captions

Captions

Add a one-line explanation of what this file represents

Summary

edit
Description
Suomi: Covid-19-rokotukset päivittäin
Date
Source Own work
Author Merikanto

Lähde: THL avoin data

Koronarokotusten edistyminen (COVID-19) Koronarokotukset Suomessa

https://thl.fi/fi/tilastot-ja-data/aineistot-ja-palvelut/avoin-data/koronarokotusten-edistyminen-covid-19

    1. covid-19 vaccinations in Finland
    2. Source: THL Open data
    3. 0000.0000 17.6.2021

library(rjstat) library(ggplot2) library(svglite) library(scales)

widthi=10 heighti=5


tulosfilee1="./Covid-19-rokotukset_1.svg"


nth_element <- function(vector, starting_position, n) {

 vector[seq(starting_position, length(vector), n)] 
 }   
 

url_base1="https://sampo.thl.fi/pivot/prod/fi/vaccreg/cov19cov/fact_cov19cov.json" measure1<-"?filter=measure-533175" ##measure1<-"?filter=measure-433796" row1<-"&row=cov_vac_dose-533170" col1="&column=dateweek20201226-525459L" request1<-paste0(measure1,row1, col1) url1<-paste0(url_base1, request1) cube1 <- fromJSONstat(url1, naming = "label", use_factors = F, silent = T) res01 <- cube11

url_base2="https://sampo.thl.fi/pivot/prod/fi/vaccreg/cov19cov/fact_cov19cov.json" measure2<-"?filter=measure-533175" row2<-"&row=cov_vac_dose-533164" col2="&column=dateweek20201226-525459L" request2<-paste0(measure2,row2, col2) url2<-paste0(url_base2, request2) cube2 <- fromJSONstat(url2, naming = "label", use_factors = F, silent = T) res02 <- cube21


paivat=as.Date(res01$dateweek20201226) ensimmainen_annos0=as.integer(res01$value) toinen_annos0=as.integer(res02$value)

ensimmainen_annos=ensimmainen_annos0 toinen_annos=toinen_annos0


#ensimmainen_annos=cumsum(ensimmainen_annos0) #toinen_annos=cumsum(toinen_annos0)

rokotukset=data.frame(paivat, ensimmainen_annos, toinen_annos) #names(rokotukset)<-c("Päivä", "Ensimmäinen annos", "Toinen annos")


#svg(filename=tulosfilee1, width=8, height=3, pointsize=12) svg(filename=tulosfilee1, width=widthi, height=heighti, pointsize=12)

rok <- data.frame(x = c(paivat, paivat), ## c

                  y = c(ensimmainen_annos, toinen_annos),    ## y
                  group = c(rep("ensimmainen_annos", length(ensimmainen_annos)), rep("toinen_annos", length(toinen_annos)) ) )   
                  


ggplot(rok, aes(x,y, group=group) )+ geom_line(aes(x, y, color = group), size=3)+ theme_light()+ ggtitle("Koronarokotukset paivittain") + xlab("Kuukausi 2021-") + ylab("Rokotetut/paiva")+ theme(title=element_text(size=18), axis.text=element_text(size=17,face="bold"),axis.title=element_text(size=19,face="bold")) + scale_color_manual( values = c("green", "blue"), name="Rokotukset", labels = c("Ensi annos", "Toinen annos"))+ theme(legend.text=element_text(size=rel(1.5)),legend.title=element_text(size=rel(1.5)) ) + theme(legend.position = c(0.2, 0.8)) + scale_y_continuous(breaks= pretty_breaks())


dev.off()


Licensing

edit
I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.

File history

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

Date/TimeThumbnailDimensionsUserComment
current08:41, 8 August 2021Thumbnail for version as of 08:41, 8 August 2021900 × 450 (93 KB)Merikanto (talk | contribs)Update
15:39, 17 June 2021Thumbnail for version as of 15:39, 17 June 2021900 × 450 (97 KB)Merikanto (talk | contribs)upload
11:49, 16 June 2021Thumbnail for version as of 11:49, 16 June 2021900 × 450 (90 KB)Merikanto (talk | contribs)Uploaded own work with UploadWizard

There are no pages that use this file.

Metadata