Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
pertz-lab
shiny-timecourse-inspector
Commits
1fcf46e8
Commit
1fcf46e8
authored
Oct 10, 2019
by
dmattek
Browse files
Fixed: no mean line if NAs present
parent
ca0500df
Changes
1
Show whitespace changes
Inline
Side-by-side
modules/trajRibbonPlot.R
View file @
1fcf46e8
...
...
@@ -313,7 +313,7 @@ modTrajRibbonPlot = function(input, output, session,
if
(
input
$
rBPlotTrajStat
==
"Mean"
)
{
# calculate the mean
loc.dt.aggr
=
loc.dt
[,
.
(
Mean
=
mean
(
get
(
COLY
))),
by
=
c
(
in.facet
,
COLRT
)]
loc.dt.aggr
=
loc.dt
[,
.
(
Mean
=
mean
(
get
(
COLY
)
,
na.rm
=
T
)),
by
=
c
(
in.facet
,
COLRT
)]
}
else
if
(
input
$
rBPlotTrajStat
==
"CI"
)
{
# calculate the mean and the confidence intervals
...
...
@@ -326,9 +326,10 @@ modTrajRibbonPlot = function(input, output, session,
}
else
if
(
input
$
rBPlotTrajStat
==
"SE"
)
{
# calculate the mean and the standard error of the mean
loc.dt.aggr
=
loc.dt
[,
.
(
Mean
=
mean
(
get
(
COLY
)),
Lower
=
mean
(
get
(
COLY
))
-
LOCstderr
(
get
(
COLY
)),
Upper
=
mean
(
get
(
COLY
))
+
LOCstderr
(
get
(
COLY
))),
by
=
c
(
in.facet
,
COLRT
)]
loc.dt.aggr
=
loc.dt
[,
.
(
Mean
=
mean
(
get
(
COLY
),
na.rm
=
T
),
Lower
=
mean
(
get
(
COLY
),
na.rm
=
T
)
-
LOCstderr
(
get
(
COLY
),
na.rm
=
T
),
Upper
=
mean
(
get
(
COLY
),
na.rm
=
T
)
+
LOCstderr
(
get
(
COLY
),
na.rm
=
T
)),
by
=
c
(
in.facet
,
COLRT
)]
loc.ribbon.lohi
=
c
(
'Lower'
,
'Upper'
)
}
...
...
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