Skip to content

Commit

Permalink
fix linter
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Sabanes Bove committed Dec 6, 2023
1 parent 9fd45a9 commit 46f080f
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions R/estimateParams.R
Original file line number Diff line number Diff line change
Expand Up @@ -76,11 +76,15 @@ prepareData <- function(data) {
#' )
#' negLogLik(transition, prepareData(simData))
negLogLik <- function(transition, data) {
with(data, -sum(log(haz(transition, exit, trans)^status
* survTrans(transition, exit, trans) / survTrans(transition, entry, trans))))
with(
data,
-sum(log(
haz(transition, exit, trans)^status * survTrans(transition, exit, trans) /
survTrans(transition, entry, trans)
))
)
}


#' Hazard Function for Different Transition Models
#'
#' @param transition (`ExponentialTransition` or `WeibullTransition`)\cr
Expand Down

0 comments on commit 46f080f

Please sign in to comment.