[PATCH 1/3] gnu: Add r-decon.

  • Done
  • quality assurance status badge
Details
3 participants
  • Aniket Patil
  • Leo Famulari
  • zimoun
Owner
unassigned
Submitted by
Aniket Patil
Severity
normal
A
A
Aniket Patil wrote on 16 Oct 2020 15:13
(address . guix-patches@gnu.org)(name . Aniket Patil)(address . aniket112.patil@gmail.com)
20201016131338.62737-1-aniket112.patil@gmail.com
* gnu/packages/cran.scm (r-decon): New variable.
---
gnu/packages/cran.scm | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)

Toggle diff (33 lines)
diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index 59a409f8e9..0370cdd993 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -24596,3 +24596,26 @@ enrichment analysis (GSEA) calculation with or without the absolute filtering.
Without filtering, users can perform (original) two-tailed or one-tailed
absolute GSEA.")
(license license:gpl2)))
+
+(define-public r-decon
+ (package
+ (name "r-decon")
+ (version "1.2-4")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "decon" version))
+ (sha256
+ (base32
+ "1v4l0xq29rm8mks354g40g9jxn0didzlxg3g7z08m0gvj29zdj7s"))))
+ (properties `((upstream-name . "decon")))
+ (build-system r-build-system)
+ (native-inputs `(("gfortran" ,gfortran)))
+ (home-page
+ "https://cran.r-project.org/web/packages/decon")
+ (synopsis
+ "Deconvolution Estimation in Measurement Error Models")
+ (description
+ "This package contains a collection of functions to deal with nonparametric measurement error problems using deconvolution kernel methods. We focus two measurement error models in the package: (1) an additive measurement error model, where the goal is to estimate the density or distribution function from contaminated data; (2) nonparametric regression model with errors-in-variables. The R functions allow the measurement errors to be either homoscedastic or heteroscedastic. To make the deconvolution estimators computationally more efficient in R, we adapt the \"Fast Fourier Transform\" (FFT) algorithm for density estimation with error-free data to the deconvolution kernel estimation. Several methods for the selection of the data-driven smoothing parameter are also provided in the package. See details in: Wang, X.F. and Wang, B. (2011). Deconvolution estimation in measurement error models: The R package decon. Journal of Statistical Software, 39(10), 1-24.")
+ (license license:gpl3+)))
+
--
2.28.0
A
A
Aniket Patil wrote on 16 Oct 2020 15:13
[PATCH 2/3] gnu: Add r-locpol.
(address . guix-patches@gnu.org)(name . Aniket Patil)(address . aniket112.patil@gmail.com)
20201016131338.62737-2-aniket112.patil@gmail.com
* gnu/packages/cran.scm (r-locpol): New variable.
---
gnu/packages/cran.scm | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)

Toggle diff (29 lines)
diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index 0370cdd993..1529849211 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -24619,3 +24619,22 @@ absolute GSEA.")
"This package contains a collection of functions to deal with nonparametric measurement error problems using deconvolution kernel methods. We focus two measurement error models in the package: (1) an additive measurement error model, where the goal is to estimate the density or distribution function from contaminated data; (2) nonparametric regression model with errors-in-variables. The R functions allow the measurement errors to be either homoscedastic or heteroscedastic. To make the deconvolution estimators computationally more efficient in R, we adapt the \"Fast Fourier Transform\" (FFT) algorithm for density estimation with error-free data to the deconvolution kernel estimation. Several methods for the selection of the data-driven smoothing parameter are also provided in the package. See details in: Wang, X.F. and Wang, B. (2011). Deconvolution estimation in measurement error models: The R package decon. Journal of Statistical Software, 39(10), 1-24.")
(license license:gpl3+)))
+(define-public r-locpol
+ (package
+ (name "r-locpol")
+ (version "0.7-0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "locpol" version))
+ (sha256
+ (base32
+ "1p915n0l09kbwkly627074jslxl01yssp1rf0c7sygvsw6sgy5lm"))))
+ (properties `((upstream-name . "locpol")))
+ (build-system r-build-system)
+ (home-page
+ "https://cran.r-project.org/web/packages/locpol")
+ (synopsis "Kernel Local Polynomial Regression")
+ (description
+ "Computes local polynomial estimators for the regression and also density. It comprises several different utilities to handle kernel estimators.")
+ (license license:gpl2+)))
--
2.28.0
A
A
Aniket Patil wrote on 16 Oct 2020 15:13
[PATCH 3/3] gnu: Add r-lpme.
(address . guix-patches@gnu.org)(name . Aniket Patil)(address . aniket112.patil@gmail.com)
20201016131338.62737-3-aniket112.patil@gmail.com
* gnu/packages/cran.scm (r-lpme): New variable.
---
gnu/packages/cran.scm | 27 +++++++++++++++++++++++++++
1 file changed, 27 insertions(+)

Toggle diff (37 lines)
diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index 1529849211..27e5db1900 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -24638,3 +24638,30 @@ absolute GSEA.")
(description
"Computes local polynomial estimators for the regression and also density. It comprises several different utilities to handle kernel estimators.")
(license license:gpl2+)))
+
+(define-public r-lpme
+ (package
+ (name "r-lpme")
+ (version "1.1.1")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "lpme" version))
+ (sha256
+ (base32
+ "0si90nkgl8bqk8yvd2igdsrngiwqh8891072pfpzipifnd0f5448"))))
+ (properties `((upstream-name . "lpme")))
+ (build-system r-build-system)
+ (propagated-inputs
+ `(("r-decon" ,r-decon)
+ ("r-flexmix" ,r-flexmix)
+ ("r-locpol" ,r-locpol)
+ ("r-rcpp" ,r-rcpp)
+ ("r-rcpparmadillo" ,r-rcpparmadillo)))
+ (home-page
+ "https://cran.r-project.org/web/packages/lpme")
+ (synopsis
+ "Nonparametric Estimation of Measurement Error Models")
+ (description
+ "Provide nonparametric methods for mean regression model, modal regression and conditional density estimation in the presence/absence of measurement error. Bandwidth selection is also provided for each method.")
+ (license license:gpl2+)))
--
2.28.0
Z
Z
zimoun wrote on 19 Oct 2020 14:09
Re: [bug#44033] [PATCH 1/3] gnu: Add r-decon.
(name . Aniket Patil)(address . aniket112.patil@gmail.com)(address . 44033@debbugs.gnu.org)
87wnzm76y4.fsf@gmail.com
Dear,

Thank you for this contribution.


The file gnu/packages/cran.scm has changed between so your patches do
not apply anymore. Could you rebase on the top? Please.

(Note that using “git format-patch --base=<hash>” where <hash> is the
hash on which your patch is applying simplifies the process. IMHO.)


On Fri, 16 Oct 2020 at 18:43, Aniket Patil <aniket112.patil@gmail.com> wrote:
Toggle quote (26 lines)
> * gnu/packages/cran.scm (r-decon): New variable.
> ---
> gnu/packages/cran.scm | 23 +++++++++++++++++++++++
> 1 file changed, 23 insertions(+)
>
> diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
> index 59a409f8e9..0370cdd993 100644
> --- a/gnu/packages/cran.scm
> +++ b/gnu/packages/cran.scm
> @@ -24596,3 +24596,26 @@ enrichment analysis (GSEA) calculation with or without the absolute filtering.
> Without filtering, users can perform (original) two-tailed or one-tailed
> absolute GSEA.")
> (license license:gpl2)))
> +
> +(define-public r-decon
> + (package
> + (name "r-decon")
> + (version "1.2-4")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (cran-uri "decon" version))
> + (sha256
> + (base32
> + "1v4l0xq29rm8mks354g40g9jxn0didzlxg3g7z08m0gvj29zdj7s"))))

The indentation does not seem correct. It should be:

(sha256
(base32
"1v4l0xq29rm8mks354g40g9jxn0didzlxg3g7z08m0gvj29zdj7s"))))

Toggle quote (4 lines)
> + (properties `((upstream-name . "decon")))
> + (build-system r-build-system)
> + (native-inputs `(("gfortran" ,gfortran)))

Usually, we use:

(native-inputs
`(("gfortran" ,gfortran)))

instead on the in-line.

Toggle quote (5 lines)
> + (home-page
> + "https://cran.r-project.org/web/packages/decon")
> + (synopsis
> + "Deconvolution Estimation in Measurement Error Models")

Usually, the synopsis is on the same line:

(synopsis "Deconvolution Estimation in Measurement Error Models")


Toggle quote (5 lines)
> + (description
> + "This package contains a collection of functions to deal with nonparametric measurement error problems using deconvolution kernel methods. We focus two measurement error models in the package: (1) an additive measurement error model, where the goal is to estimate the density or distribution function from contaminated data; (2) nonparametric regression model with errors-in-variables. The R functions allow the measurement errors to be either homoscedastic or heteroscedastic. To make the deconvolution estimators computationally more efficient in R, we adapt the \"Fast Fourier Transform\" (FFT) algorithm for density estimation with error-free data to the deconvolution kernel estimation. Several methods for the selection of the data-driven smoothing parameter are also provided in the package. See details in: Wang, X.F. and Wang, B. (2011). Deconvolution estimation in measurement error models: The R package decon. Journal of Statistical Software, 39(10), 1-24.")
> + (license license:gpl3+)))
> +

The lines should not be longer than 80 characters. Something like.

(description
"This package contains a collection of functions to deal with
nonparametric measurement error problems using deconvolution
kernel methods. We focus two measurement error models in the
package: (1) an additive measurement error model, where the goal
is to estimate the density or distribution function from
contaminated data; (2) nonparametric regression model with
errors-in-variables. The R functions allow the measurement errors
to be either homoscedastic or heteroscedastic. To make the
deconvolution estimators computationally more efficient in R, we
adapt the \"Fast Fourier Transform\" (FFT) algorithm for density
estimation with error-free data to the deconvolution kernel
estimation. Several methods for the selection of the data-driven
smoothing parameter are also provided in the package. See details
in: Wang, X.F. and Wang, B. (2011). Deconvolution estimation in
measurement error models: The R package decon. Journal of
Statistical Software, 39(10), 1-24.")


To help you to spot, you can apply the linter with:

./pre-inst-env guix lint r-deconv

and then address the warnings, if any.


Could you send a v2?

All the best,
simon
A
A
Aniket Patil wrote on 19 Oct 2020 14:27
(name . zimoun)(address . zimon.toutoune@gmail.com)(address . 44033@debbugs.gnu.org)
CAF-xJguThfaHPUMQHhywQ5Aa4qFrJNFDFYLMY7Ta1HiaTNqyng@mail.gmail.com
Sure, I will do that.

On Mon, 19 Oct 2020 at 5:40 PM, zimoun <zimon.toutoune@gmail.com> wrote:

Toggle quote (120 lines)
> Dear,
>
> Thank you for this contribution.
>
>
> The file gnu/packages/cran.scm has changed between so your patches do
> not apply anymore. Could you rebase on the top? Please.
>
> (Note that using “git format-patch --base=<hash>” where <hash> is the
> hash on which your patch is applying simplifies the process. IMHO.)
>
>
> On Fri, 16 Oct 2020 at 18:43, Aniket Patil <aniket112.patil@gmail.com>
> wrote:
> > * gnu/packages/cran.scm (r-decon): New variable.
> > ---
> > gnu/packages/cran.scm | 23 +++++++++++++++++++++++
> > 1 file changed, 23 insertions(+)
> >
> > diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
> > index 59a409f8e9..0370cdd993 100644
> > --- a/gnu/packages/cran.scm
> > +++ b/gnu/packages/cran.scm
> > @@ -24596,3 +24596,26 @@ enrichment analysis (GSEA) calculation with or
> without the absolute filtering.
> > Without filtering, users can perform (original) two-tailed or
> one-tailed
> > absolute GSEA.")
> > (license license:gpl2)))
> > +
> > +(define-public r-decon
> > + (package
> > + (name "r-decon")
> > + (version "1.2-4")
> > + (source
> > + (origin
> > + (method url-fetch)
> > + (uri (cran-uri "decon" version))
> > + (sha256
> > + (base32
> > + "1v4l0xq29rm8mks354g40g9jxn0didzlxg3g7z08m0gvj29zdj7s"))))
>
> The indentation does not seem correct. It should be:
>
> (sha256
> (base32
> "1v4l0xq29rm8mks354g40g9jxn0didzlxg3g7z08m0gvj29zdj7s"))))
>
> > + (properties `((upstream-name . "decon")))
> > + (build-system r-build-system)
> > + (native-inputs `(("gfortran" ,gfortran)))
>
> Usually, we use:
>
> (native-inputs
> `(("gfortran" ,gfortran)))
>
> instead on the in-line.
>
> > + (home-page
> > + "https://cran.r-project.org/web/packages/decon")
> > + (synopsis
> > + "Deconvolution Estimation in Measurement Error Models")
>
> Usually, the synopsis is on the same line:
>
> (synopsis "Deconvolution Estimation in Measurement Error Models")
>
>
> > + (description
> > + "This package contains a collection of functions to deal with
> nonparametric measurement error problems using deconvolution kernel
> methods. We focus two measurement error models in the package: (1) an
> additive measurement error model, where the goal is to estimate the density
> or distribution function from contaminated data; (2) nonparametric
> regression model with errors-in-variables. The R functions allow the
> measurement errors to be either homoscedastic or heteroscedastic. To make
> the deconvolution estimators computationally more efficient in R, we adapt
> the \"Fast Fourier Transform\" (FFT) algorithm for density estimation with
> error-free data to the deconvolution kernel estimation. Several methods
> for the selection of the data-driven smoothing parameter are also provided
> in the package. See details in: Wang, X.F. and Wang, B. (2011).
> Deconvolution estimation in measurement error models: The R package decon.
> Journal of Statistical Software, 39(10), 1-24.")
> > + (license license:gpl3+)))
> > +
>
> The lines should not be longer than 80 characters. Something like.
>
> (description
> "This package contains a collection of functions to deal with
> nonparametric measurement error problems using deconvolution
> kernel methods. We focus two measurement error models in the
> package: (1) an additive measurement error model, where the goal
> is to estimate the density or distribution function from
> contaminated data; (2) nonparametric regression model with
> errors-in-variables. The R functions allow the measurement errors
> to be either homoscedastic or heteroscedastic. To make the
> deconvolution estimators computationally more efficient in R, we
> adapt the \"Fast Fourier Transform\" (FFT) algorithm for density
> estimation with error-free data to the deconvolution kernel
> estimation. Several methods for the selection of the data-driven
> smoothing parameter are also provided in the package. See details
> in: Wang, X.F. and Wang, B. (2011). Deconvolution estimation in
> measurement error models: The R package decon. Journal of
> Statistical Software, 39(10), 1-24.")
>
>
> To help you to spot, you can apply the linter with:
>
> ./pre-inst-env guix lint r-deconv
>
> and then address the warnings, if any.
>
>
> Could you send a v2?
>
> All the best,
> simon
>
Attachment: file
Z
Z
zimoun wrote on 22 Oct 2020 09:59
CAJ3okZ2XLywW3Cmd6nL0OSGsiLewEHS=ytfvnXRi2Ebz=0wHWA@mail.gmail.com
Hi,

Please keep CC 44033@debbugs.gnu.org. :-)

On Thu, 22 Oct 2020 at 08:22, Aniket Patil <aniket112.patil@gmail.com> wrote:

Toggle quote (5 lines)
> Also what do you mean by
> > The file gnu/packages/cran.scm has changed between so your patches do
> > not apply anymore. Could you rebase on the top? Please.
> Do you mean that those packages are included? Or do you mean the packages aren't indented correctly?

I mean that the file gnu/packages/cran.scm has changed (new packages
that are not yours have been added) so the patches you sent do not
apply (which means that "git am" fails).

Your packages are *not* included, yet. Because they are not compliant
enough with the standard. The indentation is one the minor tweaks you
have to do.

To summary:

1. please re-read
and you can experiment with https://git-send-email.io/#step-4 (see
the other steps too) and train with for example
2. do the changes (git rebase -i)
3. rebase your branch (if any) on the top of master
4. git format-patch -v2 --base=<last-master-commit-before-your-changes>
5. git send-email --to=44033@debbugs.gnu.org ...

Does it make sense? If you are failing, do not hesitate to ask help
on #guix over IRC.


All the best,
simon
A
A
Aniket Patil wrote on 28 Oct 2020 08:51
[PATCH v2 1/3] gnu: Add r-decon.
(address . guix-patches@gnu.org)
20201028075139.157032-1-aniket112.patil@gmail.com
* gnu/packages/cran.scm (r-decon): New variable.
---
gnu/packages/cran.scm | 36 ++++++++++++++++++++++++++++++++++++
1 file changed, 36 insertions(+)

Toggle diff (46 lines)
diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index fea560f7a1..ce2d860135 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -24628,3 +24628,39 @@ orthogonal coordinate systems: cartesian, polar, spherical, cylindrical,
parabolic or user defined by custom scale factors.")
(license license:gpl3)))
+(define-public r-decon
+ (package
+ (name "r-decon")
+ (version "1.2-4")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "decon" version))
+ (sha256
+ (base32
+ "1v4l0xq29rm8mks354g40g9jxn0didzlxg3g7z08m0gvj29zdj7s"))))
+ (properties `((upstream-name . "decon")))
+ (build-system r-build-system)
+ (native-inputs
+ `(("gfortran" ,gfortran)))
+ (home-page
+ "https://cran.r-project.org/web/packages/decon")
+ (synopsis "Deconvolution Estimation in Measurement Error Models")
+ (description
+ "This package contains a collection of functions to deal with
+nonparametric measurement error problems using deconvolution
+kernel methods. We focus two measurement error models in the
+package: (1) an additive measurement error model, where the
+goal is to estimate the density or distribution function from
+contaminated data; (2) nonparametric regression model with
+errors-in-variables. The R functions allow the measurement errors
+to be either homoscedastic or heteroscedastic. To make the
+deconvolution estimators computationally more efficient in R,
+we adapt the \"Fast Fourier Transform\" (FFT) algorithm for
+density estimation with error-free data to the deconvolution
+kernel estimation. Several methods for the selection of the
+data-driven smoothing parameter are also provided in the package.
+See details in: Wang, X.F. and Wang, B. (2011). Deconvolution
+estimation in measurement error models: The R package decon.
+Journal of Statistical Software, 39(10), 1-24.")
+ (license license:gpl3+)))
--
2.28.0
A
A
Aniket Patil wrote on 28 Oct 2020 08:51
[PATCH v2 2/3] gnu: Add r-locpol.
(address . guix-patches@gnu.org)
20201028075139.157032-2-aniket112.patil@gmail.com
* gnu/packages/cran.scm (r-locpol): New variable.
---
gnu/packages/cran.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)

Toggle diff (32 lines)
diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index ce2d860135..20ebb06c67 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -24664,3 +24664,25 @@ See details in: Wang, X.F. and Wang, B. (2011). Deconvolution
estimation in measurement error models: The R package decon.
Journal of Statistical Software, 39(10), 1-24.")
(license license:gpl3+)))
+
+(define-public r-locpol
+ (package
+ (name "r-locpol")
+ (version "0.7-0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "locpol" version))
+ (sha256
+ (base32
+ "1p915n0l09kbwkly627074jslxl01yssp1rf0c7sygvsw6sgy5lm"))))
+ (properties `((upstream-name . "locpol")))
+ (build-system r-build-system)
+ (home-page
+ "https://cran.r-project.org/web/packages/locpol")
+ (synopsis "Kernel Local Polynomial Regression")
+ (description
+ "Computes local polynomial estimators for the regression and
+also density. It comprises several different utilities to handle
+kernel estimators.")
+ (license license:gpl2+)))
--
2.28.0
A
A
Aniket Patil wrote on 28 Oct 2020 08:51
[PATCH v2 3/3] gnu: Add r-lpme.
(address . guix-patches@gnu.org)
20201028075139.157032-3-aniket112.patil@gmail.com
* gnu/packages/cran.scm (r-lpme): New variable.
---
gnu/packages/cran.scm | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)

Toggle diff (39 lines)
diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index 20ebb06c67..82caaf54f6 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -24686,3 +24686,32 @@ Journal of Statistical Software, 39(10), 1-24.")
also density. It comprises several different utilities to handle
kernel estimators.")
(license license:gpl2+)))
+
+(define-public r-lpme
+ (package
+ (name "r-lpme")
+ (version "1.1.1")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "lpme" version))
+ (sha256
+ (base32
+ "0si90nkgl8bqk8yvd2igdsrngiwqh8891072pfpzipifnd0f5448"))))
+ (properties `((upstream-name . "lpme")))
+ (build-system r-build-system)
+ (propagated-inputs
+ `(("r-decon" ,r-decon)
+ ("r-flexmix" ,r-flexmix)
+ ("r-locpol" ,r-locpol)
+ ("r-rcpp" ,r-rcpp)
+ ("r-rcpparmadillo" ,r-rcpparmadillo)))
+ (home-page
+ "https://cran.r-project.org/web/packages/lpme")
+ (synopsis "Nonparametric Estimation of Measurement Error Models")
+ (description
+ "Provide nonparametric methods for mean regression model,
+modal regression and conditional density estimation in the
+presence/absence of measurement error. Bandwidth selection is
+also provided for each method.")
+ (license license:gpl2+)))
--
2.28.0
L
L
Leo Famulari wrote on 15 Dec 2020 06:39
(name . Aniket Patil)(address . aniket112.patil@gmail.com)(address . 44033-done@debbugs.gnu.org)
X9hMD+OWbth66rHA@jasmine.lan
On Wed, Oct 28, 2020 at 01:21:39PM +0530, Aniket Patil wrote:
Toggle quote (2 lines)
> * gnu/packages/cran.scm (r-lpme): New variable.

Thank you for the revised patches!

I fixed another minor linter issue: the home-page URLs redirected
permamently to similar URLs, but with trailing slashes.

Anyways, I pushed the patches as commit
1c6789464a95e98a795be84cc8f1811d411712ce:


Thanks again for the contribution!
Closed
?