-
Notifications
You must be signed in to change notification settings - Fork 0
/
ClassroomSpecificSettings.r
67 lines (41 loc) · 1.35 KB
/
ClassroomSpecificSettings.r
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
rm(list=ls())
library(rstudioapi)
my_work_dir = rstudioapi::getActiveDocumentContext()$path
my_work_dir = gsub("\\\\", "/", my_work_dir)
my_data_dir = 'data'
pathParts = strsplit(my_work_dir,'/')[[1]]
my_work_dir = paste(pathParts[1:length(pathParts)-1],sep='', collapse = "/")
setwd(my_work_dir)
libPath = paste(my_work_dir,'/','my_libs', sep="")
if (!file.exists(libPath))
{
dir.create(libPath, showWarnings = FALSE)
}
dataPath = paste(my_work_dir,'/','Data', sep="")
if (!file.exists(dataPath))
{
dir.create(dataPath, showWarnings = FALSE)
}
twitterDataPath = paste(my_work_dir,'/','Data','/','Twitter', sep="")
if (!file.exists(twitterDataPath))
{
dir.create(twitterDataPath, showWarnings = FALSE)
}
stackDataPath = paste(my_work_dir,'/','Data','/','Stack', sep="")
if (!file.exists(stackDataPath))
{
dir.create(stackDataPath, showWarnings = FALSE)
}
scopusDataPath = paste(my_work_dir,'/','Data','/','Scopus', sep="")
if (!file.exists(scopusDataPath))
{
dir.create(scopusDataPath, showWarnings = FALSE)
}
if (libPath %in% .libPaths() == FALSE)
{
.libPaths(c(libPath,.libPaths()))
}
sc_api_key = "9d8cf209ec6c67867bc44a5247ad0e52"
so_api_key = "9raZ36FkYGFHDSNrW)gdsw(("
tw_api_key = ""
getoldtweets_path = paste(my_work_dir,"/GetOldTweets-java-master", sep="")