This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(shiny) | |
library(leaflet) | |
library(shinythemes) | |
library(dplyr) | |
# See http://tuijasonkkila.fi/blog/2015/03/birds-on-a-map/ | |
# http://atlas3.lintuatlas.fi/taustaa/kaytto | |
# | |
# linnut <- read.table("lajit.csv", sep = ",", stringsAsFactors = F, quote = "") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
sparql_endpoint <- "http://dbpedia.org/sparql" | |
# Query example from https://medium.com/virtuoso-blog/dbpedia-basic-queries-bc1ac172cc09 | |
q <- " | |
SELECT ?athlete ?cityName | |
WHERE | |
{ | |
?athlete rdfs:label 'Cristiano Ronaldo'@en ; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://raw.githubusercontent.com/gkaramanis/tidytuesday/master/2021/2021-week37/billboard.R | |
# https://twitter.com/ttso/status/1442485258172043268 | |
billb_feat <- billb_feat %>% | |
mutate( | |
subgenre = case_when( | |
str_detect(spotify_genre, "rock") ~ "1", | |
str_detect(spotify_genre, "folk") ~ "2", | |
str_detect(spotify_genre, "pop") ~ "3", | |
str_detect(spotify_genre, "jazz") ~ "4", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(stringr) | |
library(tidyverse) | |
#--------------------------------------------------------------- | |
# https://twitter.com/nealhaddaway/status/1362512900716433409 | |
# | |
# His example query | |
#-------------------------------------------------------------- | |
q <- "((arable OR agricult* OR farm* OR crop* OR cultivat* OR field*) AND | |
(plough* OR plow* OR till* OR 'direct drill*' OR fertili* OR biosolid* OR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- | |
First export blog posts from WordPress, and then transform the exported XML file to HTML | |
with e.g. Saxon | |
java -jar saxon9.jar wordpress.2013-02-17.xml wp2html.xsl >wp.html | |
Tuija Sonkkila, 17.2.2013 | |
--> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(readxl) | |
library(tmaptools) | |
library(maps) | |
library(sf) | |
url <- "https://altmetric.figshare.com/ndownloader/files/20202618" | |
temp <- tempfile() | |
download.file(url, temp) | |
data <- read_excel(temp) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(sf) | |
# Data from hri.fi | |
districts <- st_read("PKS_Kartta_Rajat_KML2011/PKS_suuralue.kml") | |
hki <- districts %>% | |
filter(Name %in% c("Eteläinen", "Itäinen","Läntinen","Kaakkoinen", | |
"Keskinen","Pohjoinen","Koillinen")) %>% | |
mutate(Name_en = case_when( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(readxl) | |
library(httr) | |
#------------------------------------------------------------- | |
# hri.fi | |
# | |
# Pääkaupunkiseudun kaukolämmön tuotannon energialähteet (GWh) | |
#------------------------------------------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(shiny) | |
library(shinydashboard) | |
library(dplyr) | |
library(tidyr) | |
library(ggvis) | |
library(DT) | |
library(d3heatmap) | |
load("ref2014impact.Rda") |
NewerOlder