View source: R/prepare_data2.R
prepare_data | R Documentation |
prepare_data(): wie prepare_data2() aber ohne zusatz infos in den [] Klammern. es werden keine measure und digits ausgegeben. Die measure.vars sind das was links steht und die group.vars das was rechts steht.
This function is used to prepare the data. The return value is a list with all the information for the automatic calculation of the descriptive statistics. The data is returned as tibble::as_tibble() and contains information about the scale properties and the number of decimal places for formatting. The labels are also returned.
makeNamesNum: aus Nummern die Namen extrahieren
make_formula: Formel erstellen in berechne_all(...)
verwendet.
Hier wird cbind(a,b,c)~g
ausgegebeb.
clean_dots_formula: Formel bereinigen return: clean_dots_formula: formula - Objekt
prepare_data(...)
## S3 method for class 'formula'
prepare_data(
x,
data,
groups = NULL,
na.action = na.pass,
drop.unused.levels = FALSE,
...
)
## S3 method for class 'data.frame'
prepare_data(
data,
...,
by = "1",
groups = NULL,
na.action = na.pass,
drop.unused.levels = FALSE
)
prepare_data2(...)
## S3 method for class 'formula'
prepare_data2(
x,
data,
groups = NULL,
na.action = na.pass,
drop.unused.levels = FALSE,
...
)
## S3 method for class 'data.frame'
prepare_data2(
data,
...,
by = "1",
groups = NULL,
na.action = na.pass,
drop.unused.levels = FALSE
)
which_test(
measure,
group.class = NULL,
measure.test = NULL,
catTest = c("factor", "freq", "logical", "multi", "ratio"),
conTest = c("numeric", "integer", "mean", "median")
)
makeNamesNum(measure, data, meAsNum = grepl("^[[:digit:]]", measure))
make_formula(measurevar, groupvars = NULL)
clean_dots_formula(x, data = NULL, names_data = names(data))
## S3 method for class 'stp25data'
print(x, ...)
... |
Namen oder Nummern (y-Variablen)) |
x |
formel a + b + c ~ groups |
data |
data.frame |
groups |
condition Funktioniert noch nicht ! |
na.action |
na.pass, na.omit |
drop.unused.levels |
an factor |
by |
x-Variablen |
measure , group.class , measure.test , catTest , conTest , names_data |
helpers do not change |
meAsNum |
logical welche sind Zahlen |
measurevar , groupvars |
mamen als strings |
Liste mit Namen und Daten data, measure.vars , group.vars, condition.vars, formula, by, measure, row_name, col_name, measure.class, group.class, condition.class, digits
dat<- data.frame(sex=factor(1:2),
m1=1:2,m2=1:2, m3=1:2, m4=1:2, m5=1:2, m6=1:2, age=1:2)
dat |> prepare_data(m1 + m2 + m3 ~ sex)
dat |> prepare_data(m1 + m2 + m3 ~ sex | age)
dat<- data.frame(sex=1:2, m1=1:2,m2=1:2, m3=1:2, m4=1:2, m5=1:2, m6=1:2, geschl=1:2)
prepare_data2(~ m1 + m1 + m2 + m3 + m4, dat)
prepare_data2(~ log(m1) + m2 + m3 + m4, dat)
prepare_data2(~ m1[1] + m2 + m3 + m4, dat)
prepare_data2(~ m1[1] + m2 + m3[4,median] + m4, dat)
prepare_data2(dat, m1, m2, m3, m4)
prepare_data2(dat, 4:7)
prepare_data2(dat, m1[1], m2, m3, m4)
prepare_data2(dat, m1[1], m2, m3[4,median], m4)
prepare_data2(dat, m1, m2, m3, m4, by = ~ geschl)
prepare_data2(dat, m1[4, median], m2, m3, m4[5], by = ~ geschl)
prepare_data2(dat, 1,2,6)
## Not run:
which_test( "factor", NULL)
which_test( "factor", "logical")
which_test( "numeric", "factor")
which_test(c("median", "mean", "logical", "numeric", "multi"),
"factor",
c(NA, "ttest", NA, NA, NA))
c(
median = "contest" ,
mean = "ttest",
logical = "cattest" ,
numeric = "contest" ,
multi = "notest"
)
## End(Not run)
# measure <- c("geschl", "1" , "3:5", 1)
# stp25tools:::makeNamesNum(measure, data=dat)
## Not run:
make_formula("a", "b")
make_formula("a", c("b","c"))
make_formula("a", ~b+c)
make_formula(c("a", "d"), c("b","c"))
## End(Not run)
## Not run:
data <- data.frame(x = NA, y = NA, z = NA)
stp25tools:::clean_dots_formula(x ~ y, data)
stp25tools:::clean_dots_formula(. ~ x + y, data)
stp25tools:::clean_dots_formula(x + y ~ ., data)
stp25tools:::clean_dots_formula(~., data)
stp25tools:::formula_split(a+b~x|y)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.