SHARE
TWEET

Untitled

a guest Sep 19th, 2019 70 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. link = paste("https://raw.githubusercontent.com/",
  2.     "go95/big_data_intro/master/Abdulkadiroglou.csv",
  3.     sep = "")
  4.  
  5. articles <- read.csv(url(link))
  6. citations <- articles[,9]
  7. citations <- citations[!is.na(citations)]
  8.  
  9. n <- length(citations)
  10. h_index <- 0
  11. for(i in 1:n) {
  12.   if(citations[i] > i) {
  13.     h_index <- h_index + 1
  14.   }
  15. }
  16. print(h_index)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top