coef()/ coefficients()
: Method for base R
coef
function for plm/hplm objects. Extracts coefficient
tables from provided object.coef(plm(exampleAB$Johanna))
power_test()
: New argument ci
provides
confidence intervals for power, alpha error, and correct proportions.
New arguments
binom_test_alpha, binom_test_power, binom_test_correct
provide test against a provided proportion for alpha, power, and correct
proportions.<- design(
design n = 1, phase_design = list(A = 6, B = 9),
rtt = 0.8, level = 1.0, trend = 0.05
)
power_test(
ci = 0.95, binom_test = TRUE
design, )
plm()
, hplm()
: Added contrast argument
with values "first"
or “preceding
”. Now
model = "JW"
is deprecated and identical to
model = "B&L-B", contrast = "preceding"
.plm()
, hplm()
: Added model
"W"
. Which shifts the measurement-time variable to start
with zero. This leads to a more sensible estimation of the intercept
(where the intercept depicts the estimated score at the start).
model = "W"
is now the default. Use
model = "B&L-B"
for previous defaults.set_vars()
working.read_scdf()
now works when cvar is not the first
column.corrected_tau()
: changed default setting of
arguments to: repeated = FALSE, continuity = FALSE
. Now the
default results match the calculator developed by Tarlow.
tau_u()
: Implemented a continuity_correction (S-1
for calculating Z)
select_phases()
now works when phase variable is not
“phase”estimate_design()
was broken and is fixed now.print()
function for sc_design
fixed.transform()
: Takes a scdf and calculates or modifies
variables for each case
(transform(exampleAB, z_values = scale(values), t_values = 50 + z_values * 10)
).smd()
reporting various types of standardized mean
differences.readSC()
-> read_scdf()
writeSC()
-> write_scdf()
design_rSC()
-> design()
rSC()
-> random_scdf()
power_test()
with various extensions, optimizations,
and solved various bugs. rewrote the print
method, added an
argument duration
to print the computation duration. Added
the 'n_trials'
argument for binomial distributions.
Extended the help page.design()
and its print method. Extended the help page.
Rewrote the algorithm for the ‘binomial’ distribution.plm()
: rewrote the analysis function for binomial
tests. These now need an argument var_trials
to define the
number of trials per measurement. The dvar_percentage
argument must be set TRUE when the dependent variables are percentages
(and family = 'binomal'
).random_scdf()
. Rewrote the algorithm
for ‘poisson’ distributed measures. Rewrote the algorithm for the
‘binomial’ distribution. Extended the help page.read_scdf()
: extracts filetype from file
extension.read_scdf()
: New yaml
import options for
scdf filesAnna:
values:
A: [1, 3, 4, 5, 6, 7]
B: [8, 9, 10, 10, 11]
Toni:
values:
A: [2, 3, 4, 5, 6, 7]
B: [3, 9, 10, 10,11]
control_var: [1,2,3,4,5,6,7,8,1,2,3]
tau_u()
#51: Added option for confidence intervals for
tau_u output.describe()
: solved wrong calculation of Hedges G when
phase length differed.plm()
solved #46: throws no error, when a phase is of
length 1.corrected_tau()
solved #48: throws warning when A phase
has less than three rows.%>%
operator for some time before switching to
|>
.add_l2, select_phases, select_cases, subset, set_vars, set_dvar, set_mvar, set_pvar
.sample_names()
: Returns a character vector of length
n
with names by randomly drawing from a name list: type =
{“neutral”, “female”, “male”, “mixed”}. Useful to anonymize scdf
filesnames(exampleAB) <- sample_names(3)
-add_l2()
: Adds the variables from a second level 2 data
frame to an scdf matched by an id variable (default is
case
).
%>%
Leidig2018 add_l2(Leidig2018_l2) %>%
hplm(update.fixed = .~. + gender + migration + ITRF_TOTAL*phaseB,
slope = FALSE, random.slopes = FALSE, lr.test = FALSE)
select_phases()
: selects and recombines phases into A
and B phase (equivalent to the phases argument of various functions, but
useful when using %>% operators).%>%
exampleA1B1A2B2 select_phases(A = c(1, 3), B = c(2, 4)) %>%
overlap()
set_vars()
: change the core variables of an scdf
(arguments dvar
for dependent variable, pvar
for phase variable, and mvar
for measurement-time
variable).
set_dvar()
, set_mvar()
,
set_pvar()
: Shortcuts to set dvar, mvar, or pvar in a
piping script
e.g. exmpleAB_add %>% set_dvar("depression") %>% describe()
%>%
exampleAB_add set_vars(dv = "depression") %>%
overlap()
is.scdf()
: Tests if an object is of type “scdf” or
not.check_scdf()
: Checks for the validity of an scdf object
(mainly used for internal tests)convert()
: Creates an scdf syntax file from an scdf
object.# Create a syntax to code the scdf exampleAB and write it into an R file
convert(exampleAB, file = "cases.R")
cdc
: Applies the Conservative Dual-Criterion Method
(CDC; Fisher, Kelley, & Lomas, 2003) to scdf objects.cdc(Beretvas2008)
cdc(exampleAB_decreasing, decreasing = TRUE, trend.method = "bisplit")
overlap()
: Added Hedges-g.plot.scdf()
: Koenig’s bi-split
/ quarter intersect (lines = “trendA_bisplit”) and Tukey’s tri-split /
Wald’s slope (lines = “trendA_trisplit”).plot(exampleAB_50[8], lines = "trendA_bisplit")
plot(example_A24, lines = "trendA_trisplit")
plot.scdf()
: Now allows for multiple lines with
different line styles.plot(
exampleAB, lines = list(
list(type = "median", col = "red", lwd = 0.5),
list(type = "trend", col = "blue", lty = "dashed", lwd = 2),
list(type = "loreg", f = 0.2, col = "green", lty = "solid", lwd = 1)
) )
tau_u()
: Solved bug in meta analysis #6. Reworked
the complete function to be more clear and accurate. Added
method_meta
switching between fixed and random-effect meta
analyses. Reworked the print function to look nicer.
export()
: Reworked the html output. Added a basic
output for tau_u. Arguments caption
and
footnote
allow to specify appearance (if left NA object
specific output is generated.). booktab = TRUE
is now set
as a default for kable options.
The following functions were deprecated since 2017 and are now removed from scan:
makesingleSC()
makeSCDF()
: Please use scdf
instead.estimateSC()
: Please use
estimate_design()
power.testSC()
: Please use
power_test()
print.scdf()
now prints cases when all variable names
are wider than the current screen with.describe()
as the new alias for
describeSC()
plot.scdf()
, style_plot()
: New options to
style casenames: names
which takes a list with tag = value
structure. Example:<- style_plot()
new_style $names$side <- 3
new_style$names$line <- -1.7
new_style$names$col <- "darkred"
new_style$names$cex <- 1.5
new_style$names$at <- 20
new_style$names$adj <- 1
new_style$names$font <- 3
new_styleplot(exampleAB_decreasing, style = new_style)
plot.scdf()
, style_plot()
: Different
background colors for different phases:<- style_plot()
new_style $fill.bg <- c("aliceblue", "mistyrose1", "honeydew")
new_style$lty.seperators <- 0
new_styleplot(exampleABC, style = new_style)
plot(exampleABAB, style = c("default", "phase_shade"))
subset()
function (method from base
subset()
for selecting variables, rows, and cases. It takes
the arguments subset
, select
, and
cases
.subset(exampleAB, (values < 60 & phase == "A") | (values >= 60 & phase == "B"))
subset(exampleAB_add, select = c(-cigarrets, -depression))
subset(exampleA1B1A2B2, phase %in% c("A1", "B2"), cases = Pawel:Moritz)
select_cases()
function.select_cases(exampleAB, "Johanna", "Karolina")
select_cases(exampleAB, 1,2)
select_cases(exampleAB, "-Johanna")
SC
extension from function names
e.g. overlapSC()
becomes overlap()
see: https://jazznbass.github.io/scan-Book/the-scan-package.html#changes-with-version-0.50
CRAN release 2019-08-11
CRAN release 2016-10-15