forked from barryclark/jekyll-now
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.Rhistory
69 lines (69 loc) · 1.31 KB
/
.Rhistory
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
setwd("~/Desktop")
d <- read.csv('billboard.csv')
d <- read.csv('billboard.csv',header = TRUE)
head(d)
d <- read.csv('billboard.csv',header = TRUE)
head(d)
d <- read.csv('billboard.csv',header = TRUE,row.names = TRUE)
head(d)
d <- read.csv('billboard.csv',header = TRUE)
head(d)
d <- read.csv('billboard.csv',header = TRUE)
head(d)
sum(d$freq)
d$cs<-cumsum(d$freq)
d
length(d)
k<-1
d$chord[k]
tmp<-rep(d$chord[k],d$freq[k])
tmp
d$freq[k]
d$freq[k]*1000
d$freq[k]*100
d$freq[k]*10
## Create
D<-NULL
for (k in 1:nrow(d)) {
tmp<-rep(d$chord[k],d$freq[k]*10)
D<-rbind(D,tmp)
}
## Create
D<-NULL
for (k in 1:nrow(d)) {
print(k)
tmp<-rep(d$chord[k],d$freq[k]*10)
D<-rbind(D,tmp)
}
warnings()
tmp
## Create
D<-NULL
for (k in 1:nrow(d)) {
print(k)
tmp<-rep(d$chord[k],d$freq[k]*10)
D<-c(D,tmp)
}
table(D)
hist(D)
hist(table(D))
table(D)
head(D)
T<-table(D)
T
as.numeric(T)
sum(as.numeric(T))
as.numeric(T)/sum(as.numeric(T))
d
Sys.getenv(GITHUB_PAT)
Sys.getenv(GITHUB_PAT="")
Sys.setenv(GITHUB_PAT="")
devtools::install_github("tuomaseerola/MusicScienceData")
d <- get_OSF_csv(address = 'https://osf.io/r2x7w')
d <- onsetsync::get_OSF_csv(address = 'https://osf.io/r2x7w')
library(onsetsync)
d <- onsetsync::get_OSF_csv(address = 'https://osf.io/r2x7w')
library(onsetsync)
library(httr)
d <- onsetsync::get_OSF_csv(address = 'https://osf.io/r2x7w')
d