Skip to content

Commit

Permalink
couple of updates
Browse files Browse the repository at this point in the history
  • Loading branch information
2005m committed Mar 7, 2021
1 parent 63d0be2 commit ef28441
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Package: kit
Type: Package
Title: Data Manipulation Functions Implemented in C
Version: 0.0.7
Date: 2021-02-28
Date: 2021-03-07
Authors@R: c(person("Morgan", "Jacob", role = c("aut", "cre", "cph"), email = "[email protected]"))
Author: Morgan Jacob [aut, cre, cph]
Maintainer: Morgan Jacob <[email protected]>
Expand Down
6 changes: 3 additions & 3 deletions MD5
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
6071edd604dbeb75308cfbedc7790398 *cleanup
30a444c58adaf9b99783d22d75d60c61 *configure
9d9e977ed49308e2651e608d529519a0 *DESCRIPTION
c5bf03c9da2e03f8ee238160512ee141 *inst/NEWS.Rd
6110a9348799ed05278dfa5362906246 *DESCRIPTION
0f71fae4ba25ebd4aa9e2a39f64ab056 *inst/NEWS.Rd
a87b0f223435ed35607e8514562b8bfe *LICENSE
5df28320757432a550ff962f2f1aed20 *man/charToFact.Rd
8f19a2c9feb2f352580fd4892650f285 *man/count.Rd
Expand All @@ -26,7 +26,7 @@ fd6cda120996057e4520025e191ddaab *src/kit.h
63b898312ccf39a20bd7fbd8dcca5621 *src/Makevars.in
95e3011e37d9dde0d75f3a3819b2acd3 *src/Makevars.win
8e997b5d5d44af5cea7eafb48a4b9745 *src/nswitch.c
2f2fff920eff0e29b0d135f6b1f52be5 *src/psort.c
5d7ddc59fe1ca377d0899b582cfd3a8b *src/psort.c
44018b12fca6cccaabcd0f10deb421e4 *src/psum.c
75f88aa2b5fbc936c6de93efaa8ff236 *src/topn.c
c70104d7de206d29dc3efcf82d36c4de *src/utils.c
Expand Down
2 changes: 1 addition & 1 deletion inst/NEWS.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

\newcommand{\CRANpkg}{\href{https://CRAN.R-project.org/package=#1}{\pkg{#1}}}

\section{version 0.0.7 (2021-02-28)}{
\section{version 0.0.7 (2021-03-07)}{
\subsection{New Features}{
\itemize{
\item Function \code{\strong{charToFact}} gains a new argument \code{decreasing=FALSE} to be used
Expand Down
6 changes: 3 additions & 3 deletions src/psort.c
Original file line number Diff line number Diff line change
Expand Up @@ -419,7 +419,7 @@ SEXP cpsortR (SEXP x, SEXP decreasing, SEXP nthread, SEXP nalast, SEXP env, SEXP
if (cl) {
if ( ((na_pos != 0 && !dcr) || (na_pos == 0 && dcr && !early) || (na_pos != 0 && dcr && early)) && NAidx != nlen-1 ) {
if (NAidx >= 0) {
memmove(pvalSorted+NAidx, pvalSorted+NAidx+1, (nlen - (NAidx == 0 ? 1 : NAidx))*sizeof(SEXP));
memmove(pvalSorted+NAidx, pvalSorted+NAidx+1, (nlen - (NAidx + 1))*sizeof(SEXP));
pvalSorted[nlen-1] = NA_STRING;
}
} else if ( (na_pos == 0 && !dcr) || (na_pos != 0 && dcr) || (na_pos == 0 && dcr && early)){
Expand All @@ -431,7 +431,7 @@ SEXP cpsortR (SEXP x, SEXP decreasing, SEXP nthread, SEXP nalast, SEXP env, SEXP
} else {
if ( ((na_pos != 0 && !dcr) || (na_pos == 0 && dcr)) && NAidx != nlen-1) {
if (NAidx >= 0) {
memmove(pvalSorted+NAidx, pvalSorted+NAidx+1, (nlen - (NAidx == 0 ? 1 : NAidx))*sizeof(SEXP));
memmove(pvalSorted+NAidx, pvalSorted+NAidx+1, (nlen - (NAidx + 1))*sizeof(SEXP));
pvalSorted[nlen-1] = NA_STRING;
}
} else if ( (na_pos == 0 && !dcr) || (na_pos != 0 && dcr) ){
Expand Down Expand Up @@ -578,7 +578,7 @@ SEXP charToFactR (SEXP x, SEXP decreasing, SEXP nthread, SEXP nalast, SEXP env)
}
if ( ((na_pos != 0 && !dcr) || (na_pos == 0 && dcr)) && NAidx != n-1) {
if (NAidx >= 0) {
memmove(pvalSorted+NAidx, pvalSorted+NAidx+1, (n - (NAidx == 0 ? 1 : NAidx))*sizeof(SEXP));
memmove(pvalSorted+NAidx, pvalSorted+NAidx+1, (n - ((NAidx + 1)))*sizeof(SEXP));
pvalSorted[n-1] = NA_STRING;
}
} else if ( (na_pos == 0 && !dcr) || (na_pos != 0 && dcr) ){
Expand Down

0 comments on commit ef28441

Please sign in to comment.