Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cocoVisR
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
2
Issues
2
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stephanie Wegscheidl
cocoVisR
Commits
710f350e
Commit
710f350e
authored
Dec 12, 2018
by
Stephanie Wegscheidl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Multiple charts working, Importing Packages updated and Strucutred Code
parent
a5a702bd
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
351 additions
and
388 deletions
+351
-388
dashboard/server.R
dashboard/server.R
+334
-296
dashboard/ui.R
dashboard/ui.R
+7
-7
import/CoCoQuest_import.R
import/CoCoQuest_import.R
+0
-36
import/CoConUT_import.R
import/CoConUT_import.R
+0
-49
import/Packages.R
import/Packages.R
+10
-0
No files found.
dashboard/server.R
View file @
710f350e
This diff is collapsed.
Click to expand it.
dashboard/ui.R
View file @
710f350e
...
@@ -77,7 +77,7 @@ ui <- dashboardPage(
...
@@ -77,7 +77,7 @@ ui <- dashboardPage(
#Barchart
#Barchart
textOutput
(
"bar_explain"
),
textOutput
(
"bar_explain"
),
#uiOutput("input_hist_x"),
#uiOutput("input_hist_x"),
#
uiOutput("input_hist_y"),
#
uiOutput("input_hist_y"),
actionButton
(
"check_hist"
,
"add Barchart"
)
actionButton
(
"check_hist"
,
"add Barchart"
)
),
),
...
@@ -93,8 +93,8 @@ ui <- dashboardPage(
...
@@ -93,8 +93,8 @@ ui <- dashboardPage(
#Linechart
#Linechart
tabPanel
(
"Linechart"
,
tabPanel
(
"Linechart"
,
textOutput
(
"line_explain"
),
textOutput
(
"line_explain"
),
uiOutput
(
"input_line_x"
),
#
uiOutput("input_line_x"),
uiOutput
(
"input_line_y"
),
#
uiOutput("input_line_y"),
actionButton
(
"check_line"
,
"add Linechart"
)
actionButton
(
"check_line"
,
"add Linechart"
)
),
),
...
@@ -103,8 +103,8 @@ ui <- dashboardPage(
...
@@ -103,8 +103,8 @@ ui <- dashboardPage(
# selectInput("scat_x", "x-axis", choices=colnames(coconut.df)),
# selectInput("scat_x", "x-axis", choices=colnames(coconut.df)),
# selectInput("scat_y", "y-axis", choices=colnames(coconut.df)),
# selectInput("scat_y", "y-axis", choices=colnames(coconut.df)),
textOutput
(
"scat_explain"
),
textOutput
(
"scat_explain"
),
uiOutput
(
"input_scat_x"
),
#
uiOutput("input_scat_x"),
uiOutput
(
"input_scat_y"
),
#
uiOutput("input_scat_y"),
actionButton
(
"check_scat"
,
" add Scatterplot"
)
actionButton
(
"check_scat"
,
" add Scatterplot"
)
),
),
...
@@ -112,7 +112,7 @@ ui <- dashboardPage(
...
@@ -112,7 +112,7 @@ ui <- dashboardPage(
tabPanel
(
"Boxplot"
,
tabPanel
(
"Boxplot"
,
# selectInput("box_x", "x-axis", choices=colnames(coconut.df)),
# selectInput("box_x", "x-axis", choices=colnames(coconut.df)),
textOutput
(
"box_explain"
),
textOutput
(
"box_explain"
),
uiOutput
(
"input_box_x"
),
#
uiOutput("input_box_x"),
#uiOutput("input_box_y"),
#uiOutput("input_box_y"),
actionButton
(
"check_box"
,
"add Boxplot"
)
actionButton
(
"check_box"
,
"add Boxplot"
)
...
@@ -123,7 +123,7 @@ ui <- dashboardPage(
...
@@ -123,7 +123,7 @@ ui <- dashboardPage(
tabPanel
(
"Map"
,
tabPanel
(
"Map"
,
# selectInput("map_data", "data", choices=colnames(coconut.df)),
# selectInput("map_data", "data", choices=colnames(coconut.df)),
textOutput
(
"map_explain"
),
textOutput
(
"map_explain"
),
uiOutput
(
"input_map"
),
#
uiOutput("input_map"),
actionButton
(
"check_map"
,
"add Map"
)
actionButton
(
"check_map"
,
"add Map"
)
)
)
)
)
...
...
import/CoCoQuest_import.R
deleted
100644 → 0
View file @
a5a702bd
#CoCoQuest Import
#TODO: for all Timestamps not just first and last
Sys.setenv
(
LANG
=
"en"
)
library
(
ggplot2
)
library
(
jsonlite
)
require
(
GGally
)
library
(
dplyr
)
library
(
rgl
)
library
(
knitr
)
library
(
scales
)
library
(
stringi
)
library
(
RHRV
)
library
(
anytime
)
basedir
<-
"D:\\Dropbox\\UNI\\BAK\\Daten\\CoCoQuest\\"
datadir
<-
paste
(
basedir
,
'data/'
,
sep
=
""
)
plotdir
<-
paste
(
basedir
,
'plots/'
,
sep
=
""
)
json_file
<-
paste
(
basedir
,
"study.json"
,
sep
=
""
)
json_data_quest
<-
fromJSON
(
paste
(
json_file
,
sep
=
""
),
flatten
=
TRUE
)
cocoquest.df
<-
json_data_quest
[[
"data"
]]
#parsing timestamp into actual time
#json_data_quest$startTime <-as.numeric(js)
json_data_quest
$
unix_starttime
<-
as.numeric
(
json_data_quest
$
startTime
)
/
1000
json_data_quest
$
unix_endtime
<-
as.numeric
(
json_data_quest
$
endTime
)
/
1000
starttime
<-
anytime
(
json_data_quest
$
unix_starttime
)
endtime
<-
anytime
(
json_data_quest
$
unix_endtime
)
print
(
starttime
)
print
(
endtime
)
import/CoConUT_import.R
deleted
100644 → 0
View file @
a5a702bd
Sys.setenv
(
LANG
=
"en"
)
library
(
ggplot2
)
library
(
jsonlite
)
require
(
GGally
)
library
(
dplyr
)
library
(
rgl
)
library
(
knitr
)
library
(
scales
)
library
(
stringi
)
library
(
RHRV
)
library
(
anytime
)
basedir
<-
"D:\\Dropbox\\UNI\\BAK\\Daten\\CoConUT\\"
datadir
<-
paste
(
basedir
,
'data/'
,
sep
=
""
)
plotdir
<-
paste
(
basedir
,
'plots/'
,
sep
=
""
)
#loading data
json_file
<-
paste
(
basedir
,
"g3.json"
,
sep
=
""
)
json_data_coco
<-
fromJSON
(
paste
(
json_file
,
sep
=
""
),
flatten
=
TRUE
)
coconut.df
<-
json_data_coco
[[
"data"
]]
#parsing timestamp into actual time
coconut.df
$
unix_timestamp
<-
as.numeric
(
coconut.df
$
timestamp
)
/
1000
time
<-
anytime
(
coconut.df
$
unix_timestamp
)
# optional
coconut.df
$
second_counter
=
(
coconut.df
$
unix_timestamp
-
min
(
coconut.df
$
unix_timestamp
))
#extracting everything into variables
lux
<-
as.numeric
(
coconut.df
$
light.lux
)
latitude
<-
as.numeric
(
coconut.df
$
gps.latitude
)
longitude
<-
as.numeric
(
coconut.df
$
gps.longitude
)
bluetooth
<-
as.numeric
(
coconut.df
$
bluetooth.numOfBTDevices
)
#print everything
print
(
coconut.df
)
print
(
time
)
print
(
longitude
)
print
(
latitude
)
print
(
lux
)
print
(
bluetooth
)
# getting coordinate-tuples
coordinates
<-
cbind
(
latitude
,
longitude
)
print
(
coordinates
)
import/Packages.R
0 → 100644
View file @
710f350e
install.packages
(
"shiny"
)
install.packages
(
"shinydashboard"
)
install.packages
(
"jsonlite"
)
install.packages
(
"DT"
)
install.packages
(
"anytime"
)
install.packages
(
"leaflet"
)
install.packages
(
"timevis"
)
install.packages
(
"Cairo"
)
install.packages
(
"grDevices"
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment