You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: scripts/builtin/ampute.dml
-1Lines changed: 0 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -30,7 +30,6 @@
30
30
# 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
31
31
# 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"
32
32
# seed a manually defined seed for reproducible RNG
Copy file name to clipboardExpand all lines: src/main/python/systemds/operator/algorithm/builtin/ampute.py
+10Lines changed: 10 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -33,6 +33,16 @@ def ampute(X: Matrix,
33
33
"""
34
34
This function injects missing values into a multivariate a given dataset, similarly to the ampute() method in R's MICE package.
35
35
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
0 commit comments