projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
insert variables in var view (#55357)
[pspp]
/
src
/
math
/
categoricals.h
diff --git
a/src/math/categoricals.h
b/src/math/categoricals.h
index f427c473b788d854317e47be8e891aabed055a16..5e49b4504ab1b9338c19fe089b861fa8d82a328f 100644
(file)
--- a/
src/math/categoricals.h
+++ b/
src/math/categoricals.h
@@
-53,8
+53,8
@@
union value;
/* Creating and destroying categoricals. */
struct categoricals *categoricals_create (struct interaction *const *,
size_t n,
/* Creating and destroying categoricals. */
struct categoricals *categoricals_create (struct interaction *const *,
size_t n,
- const struct variable *wv,
- enum mv_class fctr_excl);
+
const struct variable *wv,
+
enum mv_class fctr_excl);
void categoricals_destroy (struct categoricals *);
/* Updating categoricals. */
void categoricals_destroy (struct categoricals *);
/* Updating categoricals. */
@@
-62,7
+62,7
@@
void categoricals_update (struct categoricals *, const struct ccase *);
void categoricals_done (const struct categoricals *);
bool categoricals_is_complete (const struct categoricals *);
void categoricals_done (const struct categoricals *);
bool categoricals_is_complete (const struct categoricals *);
-/* C
ounting c
ategories.
+/* Categories.
A variable's number of categories is the number of unique values observed in
the data passed to categoricals_update().
A variable's number of categories is the number of unique values observed in
the data passed to categoricals_update().
@@
-76,6
+76,9
@@
bool categoricals_is_complete (const struct categoricals *);
size_t categoricals_n_count (const struct categoricals *, size_t idx);
size_t categoricals_n_total (const struct categoricals *);
size_t categoricals_n_count (const struct categoricals *, size_t idx);
size_t categoricals_n_total (const struct categoricals *);
+union value *categoricals_get_var_values (const struct categoricals *,
+ const struct variable *, size_t *n);
+
/* Degrees of freedom.
A categorical variable with N_CATS categories has N_CATS - 1 degrees of
/* Degrees of freedom.
A categorical variable with N_CATS categories has N_CATS - 1 degrees of
@@
-142,6
+145,9
@@
const struct ccase *categoricals_get_case_by_category_real (
void *categoricals_get_user_data_by_category_real (
const struct categoricals *, int iact, int n);
void *categoricals_get_user_data_by_category_real (
const struct categoricals *, int iact, int n);
+int categoricals_get_value_index_by_category_real (
+ const struct categoricals *, int iact_idx, int cat_idx, int var_idx);
+
void *categoricals_get_user_data_by_category (const struct categoricals *,
int category);
const struct ccase *categoricals_get_case_by_category (
void *categoricals_get_user_data_by_category (const struct categoricals *,
int category);
const struct ccase *categoricals_get_case_by_category (