|
| 1 | +%global __brp_check_rpaths %{nil} |
| 2 | +%global __requires_exclude ^libmpi |
| 3 | +%global packname RegrCoeffsExplorer |
| 4 | +%global packver 1.2.0 |
| 5 | +%global rlibdir /usr/local/lib/R/library |
| 6 | + |
| 7 | +Name: R-CRAN-%{packname} |
| 8 | +Version: 1.2.0 |
| 9 | +Release: 1%{?dist}%{?buildtag} |
| 10 | +Summary: Efficient Visualization of Regression Coefficients for Lm(), Glm(), and Glmnet() Objects |
| 11 | + |
| 12 | +License: MIT + file LICENSE |
| 13 | +URL: https://cran.r-project.org/package=%{packname} |
| 14 | +Source0: %{url}&version=%{packver}#/%{packname}_%{packver}.tar.gz |
| 15 | + |
| 16 | + |
| 17 | +BuildRequires: R-devel |
| 18 | +Requires: R-core |
| 19 | +BuildArch: noarch |
| 20 | +BuildRequires: R-CRAN-dplyr |
| 21 | +BuildRequires: R-CRAN-ggpubr |
| 22 | +BuildRequires: R-CRAN-gridExtra |
| 23 | +BuildRequires: R-CRAN-glmnet |
| 24 | +BuildRequires: R-CRAN-ggplot2 |
| 25 | +BuildRequires: R-CRAN-magrittr |
| 26 | +BuildRequires: R-grDevices |
| 27 | +BuildRequires: R-CRAN-rlang |
| 28 | +BuildRequires: R-stats |
| 29 | +Requires: R-CRAN-dplyr |
| 30 | +Requires: R-CRAN-ggpubr |
| 31 | +Requires: R-CRAN-gridExtra |
| 32 | +Requires: R-CRAN-glmnet |
| 33 | +Requires: R-CRAN-ggplot2 |
| 34 | +Requires: R-CRAN-magrittr |
| 35 | +Requires: R-grDevices |
| 36 | +Requires: R-CRAN-rlang |
| 37 | +Requires: R-stats |
| 38 | + |
| 39 | +%description |
| 40 | +The visualization tool offers a nuanced understanding of regression |
| 41 | +dynamics, going beyond traditional per-unit interpretation of continuous |
| 42 | +variables versus categorical ones. It highlights the impact of unit |
| 43 | +changes as well as larger shifts like interquartile changes, acknowledging |
| 44 | +the distribution of empirical data. Furthermore, it generates |
| 45 | +visualizations depicting alterations in Odds Ratios for predictors across |
| 46 | +minimum, first quartile, median, third quartile, and maximum values, |
| 47 | +aiding in comprehending predictor-outcome interplay within empirical data |
| 48 | +distributions, particularly in logistic regression frameworks. |
| 49 | + |
| 50 | +%prep |
| 51 | +%setup -q -c -n %{packname} |
| 52 | + |
| 53 | +# fix end of executable files |
| 54 | +find -type f -executable -exec grep -Iq . {} \; -exec sed -i -e '$a\' {} \; |
| 55 | +# prevent binary stripping |
| 56 | +[ -d %{packname}/src ] && find %{packname}/src -type f -exec \ |
| 57 | + sed -i 's@/usr/bin/strip@/usr/bin/true@g' {} \; || true |
| 58 | +[ -d %{packname}/src ] && find %{packname}/src/Make* -type f -exec \ |
| 59 | + sed -i 's@-g0@@g' {} \; || true |
| 60 | +# don't allow local prefix in executable scripts |
| 61 | +find -type f -executable -exec sed -Ei 's@#!( )*/usr/local/bin@#!/usr/bin@g' {} \; |
| 62 | + |
| 63 | +%build |
| 64 | + |
| 65 | +%install |
| 66 | + |
| 67 | +mkdir -p %{buildroot}%{rlibdir} |
| 68 | +%{_bindir}/R CMD INSTALL -l %{buildroot}%{rlibdir} %{packname} |
| 69 | +test -d %{packname}/src && (cd %{packname}/src; rm -f *.o *.so) |
| 70 | +rm -f %{buildroot}%{rlibdir}/R.css |
| 71 | +# remove buildroot from installed files |
| 72 | +find %{buildroot}%{rlibdir} -type f -exec sed -i "s@%{buildroot}@@g" {} \; |
| 73 | + |
| 74 | +%files |
| 75 | +%{rlibdir}/%{packname} |
0 commit comments