From b023a80e0223741cabc7b805f2f8328049246241 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=B6k=C3=A7en=20Eraslan?= Date: Mon, 7 Oct 2019 14:31:34 -0400 Subject: [PATCH 1/4] Fix versus_rest link --- docs/tutorials.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/tutorials.rst b/docs/tutorials.rst index 95ee021..25c5ee9 100644 --- a/docs/tutorials.rst +++ b/docs/tutorials.rst @@ -32,7 +32,8 @@ Multiple tests per gene How to perform pairwise tests `pairwise `__. -How to perform group versus rest tests `versus_rest `__. +How to perform group versus rest tests `versus_rest +`__. Gene set enrichment: enrich From c27eead881f9857fafe3da82e8bbc8d76d618999 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=B6k=C3=A7en=20Eraslan?= Date: Mon, 7 Oct 2019 14:33:44 -0400 Subject: [PATCH 2/4] Remove whitespace --- docs/tutorials.rst | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/docs/tutorials.rst b/docs/tutorials.rst index 25c5ee9..e7b79e0 100644 --- a/docs/tutorials.rst +++ b/docs/tutorials.rst @@ -32,8 +32,7 @@ Multiple tests per gene How to perform pairwise tests `pairwise `__. -How to perform group versus rest tests `versus_rest -`__. +How to perform group versus rest tests `versus_rest `__. Gene set enrichment: enrich From bcf85334624e4621266d1ade554b640a491c72d6 Mon Sep 17 00:00:00 2001 From: Karin Hrovatin <47607471+Hrovatin@users.noreply.github.com> Date: Fri, 5 Mar 2021 22:41:42 +0100 Subject: [PATCH 3/4] update constraints array doc --- diffxpy/testing/tests.py | 42 +++++++++++++++++++++++----------------- 1 file changed, 24 insertions(+), 18 deletions(-) diff --git a/diffxpy/testing/tests.py b/diffxpy/testing/tests.py index c378494..fccd809 100644 --- a/diffxpy/testing/tests.py +++ b/diffxpy/testing/tests.py @@ -52,18 +52,20 @@ def _fit( :param design_loc: Design matrix of location model. :param design_loc: Design matrix of scale model. :param constraints_loc: : Constraints for location model. - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters of that constraint (which may be dependent at an earlier constraint) are indicated by a 1. :param constraints_scale: : Constraints for scale model. - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -519,9 +521,10 @@ def wald( :param constraints_loc: Constraints for location model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -552,9 +555,10 @@ def wald( :param constraints_scale: Constraints for scale model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -1896,9 +1900,10 @@ def wald( This makes sense for number of genes, time, pseudotime or space for example. :param constraints_loc: : Constraints for location model. - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -1906,9 +1911,10 @@ def wald( are indicated by a 1. It is highly recommended to only use this option together with prebuilt design matrix for the location model, dmat_loc. :param constraints_scale: : Constraints for scale model. - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters From 6ac7ac6caece9117709faa91d3889aecae0d7aae Mon Sep 17 00:00:00 2001 From: Karin Hrovatin <47607471+Hrovatin@users.noreply.github.com> Date: Fri, 5 Mar 2021 22:45:23 +0100 Subject: [PATCH 4/4] update constraints array doc --- diffxpy/fit/fit.py | 56 ++++++++++++++++++++++++++-------------------- 1 file changed, 32 insertions(+), 24 deletions(-) diff --git a/diffxpy/fit/fit.py b/diffxpy/fit/fit.py index 3e1b9e5..f8c8aa0 100644 --- a/diffxpy/fit/fit.py +++ b/diffxpy/fit/fit.py @@ -80,9 +80,10 @@ def model( :param constraints_loc: Constraints for location model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -113,9 +114,10 @@ def model( :param constraints_scale: Constraints for scale model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -289,9 +291,10 @@ def residuals( :param constraints_loc: Constraints for location model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -322,9 +325,10 @@ def residuals( :param constraints_scale: Constraints for scale model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -548,9 +552,10 @@ def model( :param constraints_loc: Constraints for location model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -581,9 +586,10 @@ def model( :param constraints_scale: Constraints for scale model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -705,9 +711,10 @@ def residuals( :param constraints_loc: Constraints for location model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters @@ -738,9 +745,10 @@ def residuals( :param constraints_scale: Constraints for scale model. Can be one of the following: - np.ndarray: - Array with constraints in rows and model parameters in columns. - Each constraint contains non-zero entries for the a of parameters that - has to sum to zero. This constraint is enforced by binding one parameter + Array with constraints in columns and model parameters in rows. + Each constraint contains non-zero entries for the constrained parameters that + have to sum to zero. For a non-constrained parameter the revelant constraint column + contains 1 in the parameter row. This constraint is enforced by binding one parameter to the negative sum of the other parameters, effectively representing that parameter as a function of the other parameters. This dependent parameter is indicated by a -1 in this array, the independent parameters