Skip to content

Commit 512b5c0

Browse files
committed
Ampute header error fix
1 parent 2807194 commit 512b5c0

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

scripts/builtin/ampute.dml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
# mech a string [either "MAR", "MNAR", or "MCAR"] specifying the missingness mechanism. Chosen "MAR" and "MNAR" settings will be overridden if a non-default weight matrix is specified
3131
# weights a weight matrix [shape: k-by-m], containing weights that will be used to calculate the weighted sum scores. Will be overridden if mech == "MCAR"
3232
# seed a manually defined seed for reproducible RNG
33-
3433
# -------------------------------------------------------------------------------------
3534
#
3635
# OUTPUT:

src/main/python/systemds/operator/algorithm/builtin/ampute.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,16 @@ def ampute(X: Matrix,
3333
"""
3434
This function injects missing values into a multivariate a given dataset, similarly to the ampute() method in R's MICE package.
3535
36+
37+
38+
:param X: a multivariate numeric dataset [shape: n-by-m]
39+
:param prop: a number in the (0, 1] range specifying the proportion of amputed rows across the entire dataset
40+
:param patterns: a pattern matrix of 0's and 1's [shape: k-by-m] where each row corresponds to a pattern. 0 indicates that a variable should have missing values and 1 indicating that a variable should remain complete
41+
:param freq: a vector [length: k] containing the relative frequency with which each pattern in the patterns matrix should occur
42+
:param mech: a string [either "MAR", "MNAR", or "MCAR"] specifying the missingness mechanism. Chosen "MAR" and "MNAR" settings will be overridden if a non-default weight matrix is specified
43+
:param weights: a weight matrix [shape: k-by-m], containing weights that will be used to calculate the weighted sum scores. Will be overridden if mech == "MCAR"
44+
:param seed: a manually defined seed for reproducible RNG
45+
:return: amputed output dataset
3646
"""
3747

3848
params_dict = {'X': X}

0 commit comments

Comments
 (0)