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
SELECT `ID`, `post_date`, `post_type`,`post_title`, `post_status`, `guid`, SUM( LENGTH(`post_content`)) AS 'Wordcount' FROM `wp_posts` GROUP BY `ID` HAVING `post_type` = 'post' AND `post_status` = 'publish' ORDER BY `Wordcount` DESC LIMIT 0, 10000 |
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
# devtools::install_github('charlie86/spotifyr') | |
library(jpeg) | |
library(grid) | |
library(ggplot2) | |
library(spotifyr) | |
library(ggthemes) | |
library(tidyverse) | |
kid_a <- get_artist_audio_features('radiohead') %>% | |
filter(album_name == 'Kid A') %>% |
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
#install.packages("tydiverse") | |
library(tidyverse) #Pour la manipulation des données (collection de packages) | |
#install.packages("dslabs") | |
library(dslabs) | |
data(gapminder) | |
head(gapminder) | |
#Filtres |
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
#Types de données : factor, date, numeric, character | |
#Stockage des données : vectors, matrix, dataframe, list | |
#Variable = stocke des éléments textuels ou numériques | |
x <- 7 | |
x | |
#Toutes les opérations mathématiques sont possibles | |
y <- 16 | |
z <- x*y #opérateurs : + - * / |
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(dplyr) | |
rename(tableau, Quantité = vecteur) | |
rename(tableau, Vitesse = superv) | |
filter(commune, Cas > 45) | |
arrange(commune,Province) | |
select(commune,Cas) | |
rename(commune, Ville = Commune) |
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("dplyr") | |
library("tidyverse") | |
library("tidytext") | |
library("ggplot2") | |
words <- titresFR %>% unnest_tokens('word','Titre') | |
rm(stopb) | |
stopb <- c("les","très","bien","on","cet","d'","le","et","la","de","pour","l'","lorsque","du","par","en","un","des","pas","dans","ils","plus","à","sont","est") |
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("dplyr") | |
library(ggplot2) | |
tableau <- as.data.frame(evolution) | |
print(tableau) | |
ggplot(data=tableau, aes(x=annee, y=print))+ | |
geom_bar(stat="identity", fill="coral") |
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
greentheme <- hc_theme ( | |
colors = c('#019875', '#52a654', '#92ae29', '#b5ae0d', '#d9ac00', '#ffa600'), #array of colors | |
chart = list( | |
backgroundColor = '#FFFFFF' | |
), | |
loading = list ( | |
hideDuration = 1000, | |
showDuration = 1000 | |
), | |
title = list( |
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
<!-- Dans le HTML --> | |
<div class="page_loader"> | |
<div id="inner"> | |
<img src="chemindugifanime.gif" alt="loader" /> | |
</div> | |
</div> | |
<!--Trouver un loader gif ? | |
Ici, par exemple : https://loading.io/ | |
--> |
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
function distance(a, b) { | |
var n = a.length, m = b.length, matrice = []; | |
for(var i=-1; i < n; i++) { | |
matrice[i]=[]; | |
matrice[i][-1]=i+1; | |
} | |
for(var j=-1; j < m; j++) { | |
matrice[-1][j]=j+1; | |
} | |
for(var i=0; i < n; i++) { |
NewerOlder