-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsave_pubmed_oneCSV.R
More file actions
49 lines (41 loc) · 1.69 KB
/
save_pubmed_oneCSV.R
File metadata and controls
49 lines (41 loc) · 1.69 KB
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
#Purpose: Compare representative data to the EEGManyPipes data
#Project: EEGManyPipes
#Paper: Trübutschek, D. et al. EEGManyPipelines: A large-scale, grass-root multi-analyst study of EEG analysis practices in the wild. (2022). doi:10.31222/osf.io/jq342
#Author: D. Truebutschek, M. C. Vinding, & Y. Yang
#Date: 17-10-2022
################################################################################
#Necessary imports
library(tidyverse)
library(optimbase)
library(ggthemes)
library(wesanderson)
library(RColorBrewer)
################################################################################
#Path definitions
if ( Sys.getenv("USER") == 'mcvinding' ){
data.path <- '/Users/mcvinding/Documents/EEGManyPipelines/metadata_summary'
} else if (Sys.getenv("USERNAME") == 'Mikkel'){
data.path <- 'C:/Users/Mikkel/Documents/EEGManyPipelines/metadata_summary'
} else if (Sys.getenv("USER") == 'darinka'){
data.path <- '/home/darinka/Documents/EEGManyPipes/metadata_summary/data'
} else if (Sys.getenv("USERNAME") == 'darinka.truebutschek'){
data.path <- 'C:/Users/darinka.truebutschek/Documents/EEGManyPipelines/metadata_summary/data'
} else {
# Paths and file for Yu-Fang
rm(list=ls())
path= dirname(rstudioapi::getActiveDocumentContext()$path)
setwd(path)
getwd()
data <- read.csv("final_data.csv")
}
setwd(data.path)
################################################################################
#Load data
data <- load('el_pubmed_cleaned.RData')
################################################################################
#Save it all as one big csv file
authors <- name
titles <- title
affiliations <- eeg_paps
df <- data.frame(authors, titles, affiliations)
write.csv(df, 'PubmedData.csv')