url: https://www.jotnw.or.jp/english/index.html
urls <- foreach(year =1999:2016, .combine = c) %do% {
paste0("https://www.jotnw.or.jp/english/", year, "data.html")
}
data<- foreach(i = 1:length(urls), .combine=rbind) %do%{
page<- readLines(urls[i]) %>% htmlParse
tx<- readHTMLTable(page, "/p")[[2]] %>% data.frame
tx[]<- lapply(tx, as.character)
tx.num<- tx[-1, ]
tx.num[,2:14] <- lapply(tx.num[,2:14], as.numeric)
colnames(tx.num) <- tx[1,] %>% unlist %>% unname
tx.num$year <- 1999+i-1
tx.num$Organ <- tx[-1,1]
tx.num}
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/1999data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2000data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2001data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2002data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2003data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2004data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2005data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2006data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2007data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2008data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2009data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2010data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2011data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2012data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2013data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2014data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2015data.html'
## Warning in readLines(urls[i]): incomplete final line found on 'https://
## www.jotnw.or.jp/english/2016data.html'
The number of kidney grafts are stable whereas the numbers of heart, liver and lung grafts are growing.
renTx <- data[data$Organ=="Kidney",]
cardTx <- data[data$Organ=="Heart",]
liverTx <- data[data$Organ=="Liver",]
lungTx <- data[data$Organ=="Lung",]
par(mfrow=c(2,2))
plot(renTx$year, renTx$total, type="b", ylim=c(50,250),
xlab="Year", main = "Number of Kidney Graft", ylab = "Number of Annual Case")
plot(cardTx$year, cardTx$total, type="b", ylim=c(0,50),
xlab="Year", main = "Number of Heart Graft", ylab = "Number of Annual Case")
plot(liverTx$year, liverTx$total, type="b", ylim=c(0,60),
xlab="Year", main = "Number of Liver Graft", ylab = "Number of Annual Case")
plot(lungTx$year, lungTx$total, type="b", ylim=c(0,60),
xlab="Year", main = "Number of Lung Graft", ylab = "Number of Annual Case")
print(data,row.names = F)
## JAN FEB MAR APR MAY JUN JUL AUG SEP OCT
## Heart 0 1 0 0 1 1 0 0 0 0
## Lung 0 0 0 0 0 0 0 0 0 0
## Liver 0 1 0 0 0 1 0 0 0 0
## Pancreas 0 0 0 0 0 0 0 0 0 0
## (Kidney-Pancreas \n\t )* 0 0 0 0 0 0 0 0 0 0
## Kidney 19 25 12 8 18 22 5 10 7 11
## (from \n\t brain death donors) 0 2 0 0 2 4 0 0 0 0
## total 19 27 12 8 19 24 5 10 7 11
## Heart 0 0 1 1 0 0 1 0 0 0
## Lung 0 0 2 0 0 0 1 0 0 0
## Liver 0 0 2 2 0 0 1 0 0 0
## Pancreas 0 0 0 1 0 0 0 0 0 0
## (Kidney-Pancreas \n\t )* 0 0 0 1 0 0 0 0 0 0
## Kidney 14 10 22 21 14 6 6 12 8 12
## (from \n\t brain death donors) 0 0 2 2 0 0 2 0 0 0
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 14 10 27 25 14 6 9 12 8 12
## Heart 2 1 1 0 0 0 1 0 0 0
## Lung 2 0 1 0 0 0 2 0 0 0
## Liver 1 1 1 0 0 0 1 1 0 0
## Pancreas 2 0 0 0 0 0 1 1 0 0
## (Kidney-Pancreas \n\t )* 2 0 0 0 0 0 1 1 0 0
## Kidney 16 4 6 8 8 6 31 18 10 16
## (from \n\t brain death donors) 4 2 2 0 0 0 4 2 0 0
## Intestine 1 0 0 0 0 0 0 0 0 0
## total 24 6 9 8 8 6 36 20 10 16
## Heart 1 0 0 0 0 0 0 1 0 0
## Lung 1 0 0 0 0 0 0 1 0 0
## Liver 2 0 0 1 0 0 0 1 0 0
## Pancreas 1 0 0 0 0 0 0 1 0 0
## (Kidney-Pancreas \n\t )* 0 0 0 0 0 0 0 1 0 0
## Kidney 14 8 14 10 8 8 10 14 4 8
## (from \n\t brain death donors) 2 0 0 2 0 0 0 2 0 0
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 19 8 14 11 8 8 10 18 4 8
## Heart 0 0 0 0 0 0 0 0 0 0
## Lung 0 0 0 0 0 0 0 0 1 1
## Liver 0 0 0 0 0 0 0 0 1 1
## Pancreas 0 0 0 0 0 0 0 0 0 2
## (Kidney-Pancreas \n\t )* 0 0 0 0 0 0 0 0 0 1
## Kidney 8 10 12 12 11 4 12 12 10 15
## (from \n\t brain death donors) 0 0 0 0 0 0 0 0 2 2
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 8 10 12 12 11 4 12 12 12 19
## Heart 0 2 0 0 1 0 1 0 0 0
## Lung 0 1 0 0 1 0 1 0 0 0
## Liver 0 1 0 0 1 0 0 0 0 0
## Pancreas 1 2 0 0 1 0 1 0 0 0
## (Kidney-Pancreas \n\t )* 1 2 0 0 1 0 1 0 0 0
## Kidney 20 19 9 13 20 14 19 14 4 16
## (from \n\t brain death donors) 0 2 0 0 2 0 2 0 0 0
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 19 27 12 8 19 24 5 10 7 11
## Heart 0 3 2 0 0 0 0 0 0 1
## Lung 0 2 1 0 0 0 0 1 0 1
## Liver 0 1 1 0 0 0 0 0 0 1
## Pancreas 0 2 1 0 0 0 0 1 0 1
## (Kidney-Pancreas \n\t\t )* 0 1 1 0 0 0 0 1 0 1
## Kidney 15 14 12 14 13 14 6 23 11 12
## (from \n\t\t brain death donors) 0 4 4 0 0 0 0 2 2 2
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 15 22 17 14 13 14 6 25 11 16
## Heart 1 0 3 0 1 2 0 0 0 2
## Lung 1 0 2 0 1 0 0 0 0 1
## Liver 0 0 1 0 1 0 0 0 0 2
## Pancreas 1 0 2 0 1 2 0 0 0 2
## (Kidney-Pancreas \n\t )* 1 0 1 0 1 2 0 0 0 2
## Kidney 16 16 24 10 20 16 13 10 19 18
## (from \n\t brain death donors) 2 0 2 0 2 4 0 0 0 4
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 19 16 32 10 24 20 13 10 19 25
## Heart 0 2 1 1 1 1 0 2 1 1
## Lung 0 3 0 1 0 0 0 1 2 1
## Liver 0 2 0 2 1 0 0 1 3 1
## Pancreas 0 2 1 1 1 1 0 2 3 1
## (Kidney-Pancreas \n\t )* 0 2 1 1 0 1 0 1 2 0
## Kidney 8 22 17 18 21 13 14 15 13 18
## (from \n\t brain death donors) 0 4 2 2 2 2 0 4 6 2
## Intestine 0 1 0 0 0 0 0 0 0 1
## total 8 32 19 23 24 15 14 21 22 23
## Heart 0 1 1 1 2 0 2 2 1 1
## Lung 0 1 0 2 2 0 3 3 2 1
## Liver 1 1 1 1 3 0 2 2 1 1
## Pancreas 0 0 1 1 3 0 2 1 1 1
## (Kidney-Pancreas )* 0 0 1 0 1 0 1 1 1 1
## Kidney 20 18 28 10 16 22 14 20 20 10
## (from brain death donors) 2 2 2 2 6 0 4 4 2 2
## Intestine 0 0 0 0 0 0 1 0 0 0
## total 21 21 31 15 26 22 24 28 25 14
## Heart 3 1 0 0 0 0 0 0 0 0
## Heart-Lung 1 0 0 0 0 0 0 0 0 0
## Lung 4 1 0 0 0 0 0 0 0 0
## Liver 4 1 0 0 0 0 0 0 0 0
## Liver-Kidney NA NA NA NA NA NA NA NA NA NA
## Pancreas 0 0 0 0 0 0 0 0 0 0
## Kidney-Pancreas 4 1 0 0 0 0 0 0 0 0
## Kidney 36 29 17 10 18 12 18 6 10 6
## (from brain death donors) 4 1 0 0 0 0 0 0 0 0
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 52 33 17 10 18 12 18 6 10 6
## Heart 3 0 0 0 0 0 0 3 7 0
## Heart-Lung 0 0 0 0 0 0 0 0 0 0
## Lung 4 0 0 0 0 0 0 5 7 0
## Liver 2 0 0 0 0 0 0 6 9 2
## Liver-Kidney NA NA NA NA NA NA NA NA NA NA
## Pancreas 0 0 0 0 0 0 0 0 1 0
## Kidney-Pancreas 3 0 0 0 0 0 0 5 5 1
## Kidney 12 16 16 10 14 14 12 14 21 10
## (from brain death donors) 3 0 0 0 0 0 0 5 13 3
## Intestine 1 0 0 0 0 0 0 1 2 0
## total 25 16 16 10 14 14 12 34 52 13
## Heart 2 5 0 5 2 3 1 1 4 2
## Heart-Lung 0 0 0 0 0 0 0 0 0 0
## Lung 3 5 0 5 5 4 2 0 5 3
## Liver 4 7 0 5 3 4 2 1 5 2
## Liver-Kidney NA NA NA NA NA NA NA NA NA NA
## Pancreas 0 0 0 0 2 0 0 0 1 0
## Kidney-Pancreas 2 6 0 5 3 2 2 1 3 2
## Kidney 11 19 6 16 19 33 10 19 9 10
## (from brain death donors) 4 7 0 5 7 8 4 1 5 2
## Intestine 0 0 0 0 0 0 1 0 1 0
## total 22 42 6 36 34 46 18 22 28 19
## Heart 2 2 1 2 1 4 0 4 5 2
## Heart-Lung 0 0 0 0 0 0 0 0 0 0
## Lung 2 4 3 1 1 2 0 6 6 1
## Liver 3 4 2 2 2 4 0 6 7 1
## Liver-Kidney 0 0 0 0 0 0 0 0 1 0
## Pancreas 0 1 0 1 0 2 0 0 1 1
## Kidney-Pancreas 1 2 0 1 0 0 0 4 4 2
## Kidney 22 12 13 13 16 9 11 21 11 14
## (from brain death donors) 7 4 4 3 4 5 0 8 7 6
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 30 25 19 20 20 21 11 41 35 21
## Heart 3 1 3 1 4 3 3 5 3 3
## Heart-Lung 0 0 0 0 0 0 0 0 0 0
## Lung 3 4 4 1 1 3 4 5 1 2
## Liver 2 2 2 1 3 2 3 6 4 2
## Liver-Kidney 0 0 0 0 0 0 0 0 0 0
## Pancreas 0 0 1 0 1 2 0 2 0 0
## Kidney-Pancreas 2 2 1 1 2 2 3 3 2 1
## Kidney 8 12 9 10 5 10 11 17 9 13
## (from brain death donors) 4 6 5 2 3 6 5 9 2 5
## Intestine 0 0 1 0 0 0 0 0 0 0
## total 18 21 21 14 16 22 24 38 19 21
## Heart 3 5 6 0 2 3 3 2 3 2
## Heart-Lung 0 0 0 0 0 0 0 0 0 0
## Lung 6 3 9 0 3 4 4 2 1 3
## Liver 4 3 7 0 2 4 4 4 3 2
## Liver-Kidney 0 1 0 0 0 0 0 0 0 0
## Pancreas 0 0 1 0 1 0 0 1 1 0
## Kidney-Pancreas 4 3 3 0 1 3 1 2 1 2
## Kidney 4 6 11 3 5 8 7 9 11 11
## (from brain death donors) 4 4 7 0 5 5 5 5 5 4
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 21 21 37 3 14 22 19 20 20 20
## Heart 4 2 6 3 4 2 3 2 2 5
## Heart-Lung 0 0 0 0 0 0 0 0 0 0
## Lung 6 4 3 2 5 2 3 4 1 2
## Liver 6 4 8 3 3 2 3 4 3 6
## Liver-Kidney 0 1 0 0 0 0 0 0 0 0
## Pancreas 0 1 1 0 0 0 0 0 1 0
## Kidney-Pancreas 3 4 3 3 2 2 3 2 0 1
## Kidney 19 7 12 9 12 12 3 14 8 11
## (from brain death donors) 11 4 8 3 10 2 3 6 6 6
## Intestine 0 0 0 0 0 0 0 0 0 0
## total 38 23 33 20 26 20 15 26 15 25
## Heart 3 0 4 6 2 3 4 8 6 5
## Heart-Lung 0 0 0 0 0 1 0 0 0 0
## Lung 2 1 3 6 3 4 6 10 2 4
## Liver 6 1 3 5 2 6 5 5 4 5
## Liver-Kidney 0 0 0 0 0 1 0 2 0 0
## Pancreas 0 0 0 1 1 0 0 2 1 0
## Kidney-Pancreas 4 0 1 4 1 4 4 3 3 2
## Kidney 8 9 17 12 5 15 8 19 17 12
## (from brain death donors) 5 1 7 8 3 5 8 13 9 4
## Intestine 0 0 0 0 0 0 0 1 0 0
## total 23 11 28 34 14 34 27 50 33 28
## NOV DEC total year Organ
## 0 0 3 1999 Heart
## 0 0 0 1999 Lung
## 0 0 2 1999 Liver
## 0 0 0 1999 Pancreas
## 0 0 0 1999 (Kidney-Pancreas \n\t )*
## 11 10 158 1999 Kidney
## 0 0 8 1999 (from \n\t brain death donors)
## 11 10 163 1999 total
## 0 0 3 2000 Heart
## 0 0 3 2000 Lung
## 1 0 6 2000 Liver
## 0 0 1 2000 Pancreas
## 0 0 3 2000 (Kidney-Pancreas \n\t )*
## 15 6 146 2000 Kidney
## 1 0 7 2000 (from \n\t brain death donors)
## 0 0 0 2000 Intestine
## 16 6 159 2000 total
## 1 0 6 2001 Heart
## 1 0 6 2001 Lung
## 1 0 6 2001 Liver
## 1 1 6 2001 Pancreas
## 1 1 6 2001 (Kidney-Pancreas \n\t )*
## 13 15 151 2001 Kidney
## 2 0 16 2001 (from \n\t brain death donors)
## 0 0 1 2001 Intestine
## 17 16 176 2001 total
## 2 1 5 2002 Heart
## 2 0 4 2002 Lung
## 3 0 7 2002 Liver
## 1 0 3 2002 Pancreas
## 1 0 2 2002 (Kidney-Pancreas \n\t )*
## 12 14 124 2002 Kidney
## 2 2 10 2002 (from \n\t brain death donors)
## 0 0 0 2002 Intestine
## 20 15 143 2002 total
## 0 0 0 2003 Heart
## 0 0 2 2003 Lung
## 0 0 2 2003 Liver
## 0 0 2 2003 Pancreas
## 0 0 1 2003 (Kidney-Pancreas \n\t )*
## 12 18 136 2003 Kidney
## 0 0 4 2003 (from \n\t brain death donors)
## 0 0 0 2003 Intestine
## 12 18 142 2003 total
## 1 0 5 2004 Heart
## 1 0 4 2004 Lung
## 1 0 3 2004 Liver
## 0 0 5 2004 Pancreas
## 0 0 5 2004 (Kidney-Pancreas \n\t )*
## 14 11 173 2004 Kidney
## 0 0 6 2004 (from \n\t brain death donors)
## 0 0 0 2004 Intestine
## 11 10 163 2004 total
## 1 0 7 2005 Heart
## 0 0 5 2005 Lung
## 1 0 4 2005 Liver
## 1 0 6 2005 Pancreas
## 1 0 5 2005 (Kidney-Pancreas \n\t\t )*
## 16 10 160 2005 Kidney
## 2 0 16 2005 (from \n\t\t brain death donors)
## 0 0 0 2005 Intestine
## 19 10 182 2005 total
## 0 1 10 2006 Heart
## 0 1 6 2006 Lung
## 0 1 5 2006 Liver
## 0 1 9 2006 Pancreas
## 0 1 8 2006 (Kidney-Pancreas \n\t )*
## 17 18 197 2006 Kidney
## 0 2 16 2006 (from \n\t brain death donors)
## 0 0 0 2006 Intestine
## 17 22 227 2006 total
## 0 0 10 2007 Heart
## 0 1 9 2007 Lung
## 0 0 10 2007 Liver
## 0 0 12 2007 Pancreas
## 0 0 8 2007 (Kidney-Pancreas \n\t )*
## 12 16 187 2007 Kidney
## 0 0 24 2007 (from \n\t brain death donors)
## 0 0 2 2007 Intestine
## 12 17 230 2007 total
## 0 0 11 2008 Heart
## 0 0 14 2008 Lung
## 0 0 13 2008 Liver
## 0 0 10 2008 Pancreas
## 0 0 6 2008 (Kidney-Pancreas )*
## 16 16 210 2008 Kidney
## 0 0 26 2008 (from brain death donors)
## 0 0 1 2008 Intestine
## 16 16 259 2008 total
## 1 1 6 2009 Heart
## 0 0 1 2009 Heart-Lung
## 2 2 9 2009 Lung
## 1 1 7 2009 Liver
## NA NA 0 2009 Liver-Kidney
## 0 0 0 2009 Pancreas
## 1 1 7 2009 Kidney-Pancreas
## 11 9 182 2009 Kidney
## 1 1 7 2009 (from brain death donors)
## 1 0 1 2009 Intestine
## 17 14 213 2009 total
## 3 7 23 2010 Heart
## 0 0 0 2010 Heart-Lung
## 5 4 25 2010 Lung
## 3 8 30 2010 Liver
## NA NA 0 2010 Liver-Kidney
## 0 1 2 2010 Pancreas
## 2 7 23 2010 Kidney-Pancreas
## 22 25 186 2010 Kidney
## 6 9 39 2010 (from brain death donors)
## 0 0 4 2010 Intestine
## 35 52 293 2010 total
## 3 3 31 2011 Heart
## 0 0 0 2011 Heart-Lung
## 2 3 37 2011 Lung
## 5 3 41 2011 Liver
## NA NA 0 2011 Liver-Kidney
## 2 1 6 2011 Pancreas
## 1 2 29 2011 Kidney-Pancreas
## 18 12 182 2011 Kidney
## 10 4 57 2011 (from brain death donors)
## 1 0 3 2011 Intestine
## 32 24 329 2011 total
## 4 1 28 2012 Heart
## 0 0 0 2012 Heart-Lung
## 4 3 33 2012 Lung
## 6 3 40 2012 Liver
## 0 0 1 2012 Liver-Kidney
## 3 0 9 2012 Pancreas
## 2 2 18 2012 Kidney-Pancreas
## 16 16 174 2012 Kidney
## 6 4 58 2012 (from brain death donors)
## 0 0 0 2012 Intestine
## 35 25 303 2012 total
## 4 4 37 2013 Heart
## 0 1 1 2013 Heart-Lung
## 7 5 40 2013 Lung
## 7 4 38 2013 Liver
## 0 1 1 2013 Liver-Kidney
## 2 1 9 2013 Pancreas
## 2 3 24 2013 Kidney-Pancreas
## 14 12 130 2013 Kidney
## 10 6 63 2013 (from brain death donors)
## 0 0 1 2013 Intestine
## 36 31 281 2013 total
## 5 3 37 2014 Heart
## 0 0 0 2014 Heart-Lung
## 3 3 41 2014 Lung
## 6 4 43 2014 Liver
## 0 1 2 2014 Liver-Kidney
## 0 1 5 2014 Pancreas
## 1 3 24 2014 Kidney-Pancreas
## 12 14 101 2014 Kidney
## 9 6 59 2014 (from brain death donors)
## 0 0 0 2014 Intestine
## 27 29 253 2014 total
## 5 6 44 2015 Heart
## 0 0 0 2015 Heart-Lung
## 3 10 45 2015 Lung
## 5 8 55 2015 Liver
## 0 1 2 2015 Liver-Kidney
## 1 0 4 2015 Pancreas
## 4 5 32 2015 Kidney-Pancreas
## 12 14 133 2015 Kidney
## 6 6 71 2015 (from brain death donors)
## 0 0 0 2015 Intestine
## 30 44 315 2015 total
## NA NA 41 2016 Heart
## NA NA 1 2016 Heart-Lung
## NA NA 41 2016 Lung
## NA NA 42 2016 Liver
## NA NA 3 2016 Liver-Kidney
## NA NA 5 2016 Pancreas
## NA NA 26 2016 Kidney-Pancreas
## NA NA 122 2016 Kidney
## NA NA 63 2016 (from brain death donors)
## NA NA 1 2016 Intestine
## NA NA 282 2016 total