SCM

[#6578] .createSurvObj silently ignores coeff argument

Date:
2018-04-25 17:17
Priority:
3
State:
Open
Submitted by:
William Petry (wpetry)
Assigned to:
Nobody (None)
Hardware:
None
Product:
None
Operating System:
None
Component:
None
Version:
None
Severity:
major
Resolution:
None
URL:
Summary:
.createSurvObj silently ignores coeff argument

Detailed description
When user supplies coefficients to makeSurvObj(), they are silently ignored and random values are used instead. Reprex:

set.seed(3204)
sv1 <- IPMpack::.createSurvObj(Formula = surv ~ size + covariate, coeff = c(1, 1, 1))
sv1@fit$coefficients # NOT equal to user-supplied values

sv2 <- IPMpack::.createSurvObj(Formula = surv ~ size + covariate, coeff = c(1, 1, 1))
sv2@fit$coefficients # different coefficients, still NOT equal to user-supplied values

I've attached a patched version of this function (new code on line 17).

source("hidden.createSurvObj.R")
sv3 <- .createSurvObj(Formula = surv ~ size + covariate, coeff = c(1, 1, 1))
sv3@fit$coefficients # works

Comments:

No Comments Have Been Posted

Attached Files:

Attachments:
Size Name Date By Download
687 byteshidden.createSurvObj.R2018-04-25 17:17wpetryhidden.createSurvObj.R

Changes

Field Old Value Date By
File Added5166: hidden.createSurvObj.R2018-04-25 17:17wpetry
Thanks to:
Vienna University of Economics and Business Powered By FusionForge