Skip to content

Commit

Permalink
removed unnecessary while loop
Browse files Browse the repository at this point in the history
  • Loading branch information
hanase committed Sep 26, 2024
1 parent f1ab941 commit ff61dd6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: bayesTFR
Version: 7.4-2.9005
Date: 2024-09-25
Version: 7.4-2.9006
Date: 2024-09-26
Title: Bayesian Fertility Projection
Author: Hana Sevcikova ([email protected]), Leontine Alkema ([email protected]), Peiran Liu ([email protected]), Adrian Raftery ([email protected]), Bailey Fosdick ([email protected]), Patrick Gerland ([email protected])
Maintainer: Hana Sevcikova <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion R/mcmc_ini.R
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ find.lambda.for.one.country <- function(tfr, T_end, annual = FALSE) {
lambda <- min(which(year.bin == lambda) + 2, Tendorig)
if (Tendorig - lambda < 5) { # if in the last (observed) time period, set it to the end of the period
lambda <- Tendorig
while(is.na(tfrorig[lambda])) lambda <- lambda - 1 # move it before the last NA if any
#while(is.na(tfrorig[lambda])) lambda <- lambda - 1 # move it before the last NA if any - not needed anymore
}
}

Expand Down

0 comments on commit ff61dd6

Please sign in to comment.